fix: Multiple related store things

This commit is contained in:
Sorunome 2020-10-25 16:59:55 +01:00
commit c58df5c99c
8 changed files with 37 additions and 241 deletions

View file

@ -13,14 +13,14 @@ abstract class SentryController {
confirmText: L10n.of(context).ok,
cancelText: L10n.of(context).no,
);
final storage = await getLocalStorage();
await storage.setItem('sentry', enableSentry);
final storage = Store();
await storage.setItem('sentry', enableSentry.toString());
BotToast.showText(text: L10n.of(context).changesHaveBeenSaved);
return;
}
static Future<bool> getSentryStatus() async {
final storage = await getLocalStorage();
return storage.getItem('sentry') as bool;
final storage = Store();
return await storage.getItem('sentry') == 'true';
}
}