JackLee1993 commented on a change in pull request #1475: update StringUtils 
isBlank and add isNotBlank method
URL: https://github.com/apache/incubator-dubbo/pull/1475#discussion_r175792671
 
 

 ##########
 File path: 
dubbo-common/src/main/java/com/alibaba/dubbo/common/utils/StringUtils.java
 ##########
 @@ -48,9 +48,18 @@ private StringUtils() {
     }
 
     public static boolean isBlank(String str) {
-        if (str == null || str.length() == 0)
-            return true;
-        return false;
+        if (isEmpty(str)) return true;
+
+        for (int i = 0; i < str.length(); i++) {
 
 Review comment:
   嗯,这块语义是我搞错了,之前这块的功能是可以的。我这块提交参考了apache和spring的实现,可能更好一点。

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to