Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

[mob][photos] exception handlign works in isolate

laurenspriemba083fff70b1
diff --git a/mobile/lib/ui/settings/ml/ml_user_dev_screen.dart b/mobile/lib/ui/settings/ml/ml_user_dev_screen.dart
index 1f75c95d5b..c50ede988f 100644
--- a/mobile/lib/ui/settings/ml/ml_user_dev_screen.dart
+++ b/mobile/lib/ui/settings/ml/ml_user_dev_screen.dart
@@ -62,8 +62,17 @@ class MLUserDeveloperOptions extends StatelessWidget {
buttonType: ButtonType.neutral,
labelText: "Log something in isolate",
onTap: () async {
- final boolean = await MLComputer.instance.testLogging();
- showShortToast(context, "Done: $boolean");
+ try {
+ final boolean =
+ await MLComputer.instance.testLogging();
+ showShortToast(context, "Done: $boolean");
+ } catch (e) {
+ // ignore: unawaited_futures
+ showGenericErrorDialog(
+ context: context,
+ error: e,
+ );
+ }
},
),
const SafeArea(