Stop interpolating raw exception into settings snackbar

Defense-in-depth: the persisted value is the (XOR-obfuscated) API key,
so a future SharedPreferences backend that surfaced the value in its
exception could leak it through the UI. Log the detail via debugPrint
and show a fixed message to the user instead.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
rzuasti
2026-05-31 19:00:38 -04:00
co-authored by Claude Sonnet 4.6
parent 140ebab035
commit 9b521e0847
+2 -1
View File
@@ -89,8 +89,9 @@ class _SettingsState extends State<Settings> {
UISnackbars.showError(context, 'Failed to save settings');
}
} catch (e) {
debugPrint('Failed to save settings: $e');
if (!mounted) return;
UISnackbars.showError(context, 'Failed to save settings: $e');
UISnackbars.showError(context, 'Failed to save settings');
}
}