tabish121 commented on code in PR #6304:
URL: https://github.com/apache/artemis/pull/6304#discussion_r3012312214


##########
artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/proton/AMQPConnectionContext.java:
##########
@@ -729,6 +730,9 @@ private boolean validateUser(Connection connection) throws 
Exception {
          if (saslResult instanceof PlainSASLResult plainSASLResult) {
             password = plainSASLResult.getPassword();
          }
+         if (saslResult instanceof TokenSASLResult tokenSASLResult) {

Review Comment:
   This should be an else-if since its only one or the other



##########
artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/proton/AMQPConnectionContext.java:
##########
@@ -988,6 +992,9 @@ public String getPassword() {
             if (saslResult instanceof PlainSASLResult plainSASLResult) {
                password = plainSASLResult.getPassword();
             }
+            if (saslResult instanceof TokenSASLResult tokenSASLResult) {

Review Comment:
   Also should just be an else-if 



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