notzero1995 commented on a change in pull request #13073:
URL: https://github.com/apache/shardingsphere/pull/13073#discussion_r730847348



##########
File path: 
shardingsphere-jdbc/shardingsphere-jdbc-spring/shardingsphere-jdbc-spring-infra/shardingsphere-jdbc-spring-namespace-infra/src/main/java/org/apache/shardingsphere/spring/namespace/registry/ShardingSphereAlgorithmBeanRegistry.java
##########
@@ -45,8 +45,7 @@
         String algorithmFactoryBeanClassName = 
algorithmFactoryBeanClass.getName();
         Map<String, RuntimeBeanReference> result = new 
ManagedMap<>(beanDefinitionNames.length);
         for (String each : beanDefinitionNames) {
-            String beanClassName = 
parserContext.getRegistry().getBeanDefinition(each).getBeanClassName();
-            if (null != beanClassName && 
beanClassName.equals(algorithmFactoryBeanClassName)) {
+            if 
(algorithmFactoryBeanClassName.equals(parserContext.getRegistry().getBeanDefinition(each).getBeanClassName()))
 {

Review comment:
       The code logic is no different, but the code is more clean. Another 
reason is to make up for my promise. So it doesn’t matter if there is no 
approval, I will close it as soon as possible




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


Reply via email to