printError function
void
printError(
- dynamic err, [
- dynamic trace,
- dynamic message
Implementation
void printError(dynamic err, [dynamic trace, dynamic message]) {
if (!foundation.kDebugMode) {
return;
}
final shouldHide = trace == null ||
'$trace'.isEmpty ||
'$trace'.contains('package:inspireui');
if (shouldHide) {
logger.d(err, error: message, stackTrace: StackTrace.empty);
return;
}
logger.e(err, error: message ?? 'Stack trace:', stackTrace: trace);
}