fix: Show bootstrap dialog in the appropriate places
This commit is contained in:
parent
ba3cf3a91f
commit
7a08592a1e
3 changed files with 33 additions and 42 deletions
|
|
@ -92,25 +92,7 @@ class SettingsSecurityController extends State<SettingsSecurity> {
|
|||
}
|
||||
}
|
||||
|
||||
void bootstrapSettingsAction() async {
|
||||
if (await Matrix.of(context).client.encryption.keyManager.isCached()) {
|
||||
if (OkCancelResult.ok ==
|
||||
await showOkCancelAlertDialog(
|
||||
useRootNavigator: false,
|
||||
context: context,
|
||||
title: L10n.of(context).keysCached,
|
||||
message: L10n.of(context).wipeChatBackup,
|
||||
isDestructiveAction: true,
|
||||
okLabel: L10n.of(context).ok,
|
||||
cancelLabel: L10n.of(context).cancel,
|
||||
)) {
|
||||
await BootstrapDialog(
|
||||
client: Matrix.of(context).client,
|
||||
wipe: true,
|
||||
).show(context);
|
||||
}
|
||||
return;
|
||||
}
|
||||
void showBootstrapDialog(BuildContext context) async {
|
||||
await BootstrapDialog(
|
||||
client: Matrix.of(context).client,
|
||||
).show(context);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue