fpapon commented on issue #1057: URL: https://github.com/apache/shiro/issues/1057#issuecomment-1704324742
@xian1295004710 HasAtLeastOnePermission is always = true only for the latest valid permission of the list, if a check is false, the variable is not set, I think this is your misunderstanding. The logic is that if we don't find any permitted permission in the list, we check the first permission to raise an error with a message related to the check. Side note: We can optimize a little by adding a break into the loop after setting **hasAtLeatOnePermission** to true. -- 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]
