errorException method
Implementation
Future<void> errorException(BuildContext context, dynamic error,
{bool realyError = true}) async {
String message = 'Erro desconhecido';
print(error.toString());
message = error.toString();
message = message.replaceAll('Exception:', '');
try {
return showDialog<void>(
context: context,
barrierDismissible: false,
builder: (BuildContext context) {
return OmegaErrorDialogWidget(
description: message,
textColor: OmegaLibConfig.dialogFieldStyle.textColor,
bgColor: OmegaLibConfig.dialogFieldStyle.bgColor,
);
},
);
} catch (error) {
print(error);
}
}