setDebugMode static method
Presents debug logs when isDebugEnabled
is set to true.
Implementation
static Future<void> setDebugMode({bool isDebugEnabled = true}) async {
WidgetsFlutterBinding.ensureInitialized();
try {
if (isDebugEnabled) {
Logger.debugEnabled();
}
Map<String, bool> arguments = {IS_DEBUG_ENABLED: isDebugEnabled};
return await PendoChannel.invokeMethod(SET_DEBUG_MODE, arguments);
} catch (e) {
throw 'Failed calling $SET_DEBUG_MODE with $IS_DEBUG_ENABLED: $isDebugEnabled, error is: $e';
}
}