vttranlina commented on code in PR #2412:
URL: https://github.com/apache/james-project/pull/2412#discussion_r1765390952


##########
mailet/amqp/src/main/java/org/apache/james/transport/mailets/AmqpForwardAttribute.java:
##########
@@ -183,6 +195,12 @@ String preInit(MailetConfig mailetConfig) throws 
MailetException {
             throw new MailetException("No value for " + EXCHANGE_PARAMETER_NAME
                     + " parameter was provided.");
         }
+        exchangeType = 
mailetConfig.getInitParameter(EXCHANGE_TYPE_PARAMETER_NAME);
+        if (StringUtils.isNotEmpty(exchangeType) && 
!VALIDATE_EXCHANGE_TYPES.contains(exchangeType)) {

Review Comment:
   the empty `exchangeType` (from mailet parameter configuration) is accepted. 
   it help compatibility with old code. 
   
   The test case already exists in AmqpForwardAttributeTest.java (the old code 
passes).
   
   



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