You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by GitBox <gi...@apache.org> on 2019/01/08 04:22:24 UTC

[GitHub] wqyfavor closed pull request #2015: [iOS] fix customEnvironment crash

wqyfavor closed pull request #2015: [iOS] fix customEnvironment crash
URL: https://github.com/apache/incubator-weex/pull/2015
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/ios/sdk/WeexSDK/Sources/Utility/WXLog.m b/ios/sdk/WeexSDK/Sources/Utility/WXLog.m
index c8813bf72d..2be15b101e 100644
--- a/ios/sdk/WeexSDK/Sources/Utility/WXLog.m
+++ b/ios/sdk/WeexSDK/Sources/Utility/WXLog.m
@@ -85,11 +85,8 @@ + (instancetype)sharedInstance
 
 + (void)setLogLevel:(WXLogLevel)level
 {
-    if (((WXLog*)[self sharedInstance])->_logLevel != level) {
-        ((WXLog*)[self sharedInstance])->_logLevel = level;
+    ((WXLog*)[self sharedInstance])->_logLevel = level;
 
-        [[WXSDKManager bridgeMgr] resetEnvironment];
-    }
 #pragma clang diagnostic push
 #pragma clang diagnostic ignored "-Warc-performSelector-leaks"
     Class propertyClass = NSClassFromString(@"WXTracingViewControllerManager");
diff --git a/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m b/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
index 740fd4c42c..1d6b6e690b 100644
--- a/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
+++ b/ios/sdk/WeexSDK/Sources/Utility/WXUtility.m
@@ -193,7 +193,6 @@ + (NSDictionary *)getEnvironment
                                     @"deviceWidth":@(deviceWidth * scale),
                                     @"deviceHeight":@(deviceHeight * scale),
                                     @"scale":@(scale),
-                                    @"logLevel":[WXLog logLevelString] ?: @"error",
                                     @"layoutDirection": [self getEnvLayoutDirection] == WXLayoutDirectionRTL ? @"rtl" : @"ltr"
                                 }];
     


 

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services