Arsnael commented on code in PR #1561:
URL: https://github.com/apache/james-project/pull/1561#discussion_r1239288289


##########
server/protocols/jmap-rfc-8621/src/main/scala/org/apache/james/jmap/mail/EmailSubmissionSet.scala:
##########
@@ -120,25 +128,30 @@ case class EmailSubmissionSetResponse(accountId: 
AccountId,
 
 case class EmailSubmissionId(value: Id)
 
-case class EmailSubmissionCreationResponse(id: EmailSubmissionId)
-
-case class EmailSubmissionAddress(email: MailAddress)
+case class EmailSubmissionCreationResponse(id: EmailSubmissionId, sendAt: 
UTCDate = UTCDate(ZonedDateTime.ofInstant(DATE, ZoneId.of("Z"))))
+case class ParameterName(value: String) extends AnyVal
+case class ParameterValue(value: String) extends AnyVal
+case class EmailSubmissionAddress(email: MailAddress, parameters: 
Option[Map[ParameterName, Option[ParameterValue]]] = Option.empty)
 
 case class Envelope(mailFrom: EmailSubmissionAddress, rcptTo: 
List[EmailSubmissionAddress])
 
 object EmailSubmissionCreationRequest {
   private val assignableProperties = Set("emailId", "envelope", "identityId", 
"onSuccessUpdateEmail")
 
-  def validateProperties(jsObject: JsObject): 
Either[EmailSubmissionCreationParseException, JsObject] =
+  def validateProperties(jsObject: JsObject): 
Either[EmailSubmissionCreationParseException, JsObject] = {
     jsObject.keys.diff(assignableProperties) match {
       case unknownProperties if unknownProperties.nonEmpty =>
         Left(EmailSubmissionCreationParseException(SetError.invalidArguments(
           SetErrorDescription("Some unknown properties were specified"),
           Some(toProperties(unknownProperties.toSet)))))
       case _ => scala.Right(jsObject)
+
     }

Review Comment:
   That bracket pair "{}" at this line blongs to the match pattern (so need to 
keep it). The one on the line below is the redundant one. Likely missed it 
yesterday (but lots of cleanup, accept a few mistakes thanks) but that comment 
is not well placed either IMO
   
   @thanhbv200585 remove the pair of brackets of the method, they are not 
needed. Thanks



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to