You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by bo...@apache.org on 2017/09/12 14:18:39 UTC

[2/6] incubator-weex git commit: * [ios] fix blankString when class is not NSString

* [ios] fix blankString when class is not NSString


Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/b645d802
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/b645d802
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/b645d802

Branch: refs/heads/0.16-dev
Commit: b645d8027068202a9f7c35dfc4b00b4f6c12f938
Parents: 5e3b129
Author: acton393 <zh...@gmail.com>
Authored: Tue Sep 12 21:11:15 2017 +0800
Committer: acton393 <zh...@gmail.com>
Committed: Tue Sep 12 21:11:15 2017 +0800

----------------------------------------------------------------------
 ios/sdk/WeexSDK/Sources/Utility/WXUtility.m | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/b645d802/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m b/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
index 5487525..81b2ecd 100644
--- a/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
+++ b/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
@@ -326,6 +326,10 @@ CGFloat WXFloorPixelValue(CGFloat value)
 }
 
 + (BOOL)isBlankString:(NSString *)string {
+    if (![string isKindOfClass:[NSString class]]) {
+        WXLogError(@"%@ is not a string", string);
+        return true;
+    }
     if (string == nil || string == NULL || [string isKindOfClass:[NSNull class]]) {
         return true;
     }