Showing
3 changed files
with
5 additions
and
3 deletions
| @@ -5,7 +5,7 @@ import 'package:get/src/state_manager/rx/rx_interface.dart'; | @@ -5,7 +5,7 @@ import 'package:get/src/state_manager/rx/rx_interface.dart'; | ||
| 5 | class GetConfig { | 5 | class GetConfig { | 
| 6 | static SmartManagement smartManagement = SmartManagement.full; | 6 | static SmartManagement smartManagement = SmartManagement.full; | 
| 7 | static bool isLogEnable = true; | 7 | static bool isLogEnable = true; | 
| 8 | - static LogWriterCallback log; | 8 | + static LogWriterCallback log = defaultLogWriterCallback; | 
| 9 | static String currentRoute; | 9 | static String currentRoute; | 
| 10 | } | 10 | } | 
| 11 | 11 | 
| @@ -773,7 +773,9 @@ extension GetNavigation on GetInterface { | @@ -773,7 +773,9 @@ extension GetNavigation on GetInterface { | ||
| 773 | if (enableLog != null) { | 773 | if (enableLog != null) { | 
| 774 | GetConfig.isLogEnable = enableLog; | 774 | GetConfig.isLogEnable = enableLog; | 
| 775 | } | 775 | } | 
| 776 | - GetConfig.log = logWriterCallback; | 776 | + if (logWriterCallback != null) { | 
| 777 | + GetConfig.log = logWriterCallback; | ||
| 778 | + } | ||
| 777 | if (defaultPopGesture != null) { | 779 | if (defaultPopGesture != null) { | 
| 778 | this.defaultPopGesture = defaultPopGesture; | 780 | this.defaultPopGesture = defaultPopGesture; | 
| 779 | } | 781 | } | 
| @@ -204,7 +204,7 @@ class GetMaterialApp extends StatelessWidget { | @@ -204,7 +204,7 @@ class GetMaterialApp extends StatelessWidget { | ||
| 204 | 204 | ||
| 205 | Get.config( | 205 | Get.config( | 
| 206 | enableLog: enableLog ?? GetConfig.isLogEnable, | 206 | enableLog: enableLog ?? GetConfig.isLogEnable, | 
| 207 | - logWriterCallback: logWriterCallback ?? defaultLogWriterCallback, | 207 | + logWriterCallback: logWriterCallback, | 
| 208 | defaultTransition: defaultTransition ?? Get.defaultTransition, | 208 | defaultTransition: defaultTransition ?? Get.defaultTransition, | 
| 209 | defaultOpaqueRoute: opaqueRoute ?? Get.isOpaqueRouteDefault, | 209 | defaultOpaqueRoute: opaqueRoute ?? Get.isOpaqueRouteDefault, | 
| 210 | defaultPopGesture: popGesture ?? Get.isPopGestureEnable, | 210 | defaultPopGesture: popGesture ?? Get.isPopGestureEnable, | 
- 
Please register or login to post a comment