chibenwa commented on a change in pull request #803:
URL: https://github.com/apache/james-project/pull/803#discussion_r772207084



##########
File path: 
server/container/guice/protocols/jmap/src/main/java/org/apache/james/jmap/draft/JMAPModule.java
##########
@@ -207,7 +207,7 @@ JMAPDraftConfiguration 
provideDraftConfiguration(PropertiesProvider propertiesPr
                 .keystoreType(configuration.getString("tls.keystoreType", 
null))
                 .secret(configuration.getString("tls.secret", null))
                 .jwtPublicKeyPem(loadPublicKey(fileSystem, 
ImmutableList.copyOf(configuration.getStringArray("jwt.publickeypem.url"))))
-                
.authenticationStrategies(Optional.ofNullable(configuration.getList(String.class,
 "authentication.strategy.draft", null)))
+                
.authenticationStrategies(Optional.ofNullable(ImmutableList.copyOf(configuration.getStringArray("authentication.strategy.draft"))))

Review comment:
       The Optional.ofNullable is not needed ? Or the null case throws a NPE...

##########
File path: 
server/protocols/jmap-rfc-8621/src/main/scala/org/apache/james/jmap/core/JmapRfc8621Configuration.scala
##########
@@ -60,7 +61,7 @@ object JmapRfc8621Configuration {
         .getOrElse(UPLOAD_LIMIT_DEFAULT),
       maxTimeoutSeconds = 
Optional.ofNullable(configuration.getInteger(WEB_PUSH_MAX_TIMEOUT_SECONDS_PROPERTY,
 null)).map(Integer2int).toScala,
       maxConnections = 
Optional.ofNullable(configuration.getInteger(WEB_PUSH_MAX_CONNECTIONS_PROPERTY, 
null)).map(Integer2int).toScala,
-      authenticationStrategies = 
Optional.ofNullable(configuration.getList(classOf[String], 
AUTHENTICATION_STRATEGIES, null)).toScala)
+      authenticationStrategies = 
Optional.ofNullable(ImmutableList.copyOf(configuration.getStringArray(AUTHENTICATION_STRATEGIES))).toScala)

Review comment:
       Idem 
   
   The Optional.ofNullable is not needed ? Or the null case throws a NPE...
   




-- 
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