perf: extension onStart hook will block task create (#844)

This commit is contained in:
Levi authored and GitHub committed 2024-12-21 09:58:33 +08:00
1 parent 81dfc073a6
commit 2cb93a03e2
2 files changed
+11 -5

No files matched your search

+10 -3
View File
@@ -8,9 +8,16 @@ void showErrorMessage(msg) {
Get.snackbar(title, msg.msg!);
return;
}
if (msg is Exception && (msg as dynamic).message is Result) {
Get.snackbar(title, ((msg as dynamic).message as Result).msg!);
return;
if (msg is Exception) {
final message = (msg as dynamic).message;
if (message is Result) {
Get.snackbar(title, ((msg as dynamic).message as Result).msg!);
return;
}
if (message is String) {
Get.snackbar(title, message);
return;
}
}
Get.snackbar(title, msg.toString());
}