mirror of
https://github.com/Yubico/yubioath-flutter.git
synced 2024-11-22 16:32:01 +03:00
Set current section to Home on Factory Reset cancel
This commit is contained in:
parent
46b4afe030
commit
e21fb7525c
@ -130,9 +130,16 @@ class _ResetDialogState extends ConsumerState<ResetDialog> {
|
||||
? () {
|
||||
_currentStep = -1;
|
||||
_subscription?.cancel();
|
||||
if (isAndroid) {
|
||||
_resetSection();
|
||||
}
|
||||
}
|
||||
: null,
|
||||
_ => isAndroid && _application != null
|
||||
? () {
|
||||
_resetSection();
|
||||
}
|
||||
: null,
|
||||
_ => null,
|
||||
},
|
||||
actions: [
|
||||
if (_currentStep < _totalSteps)
|
||||
@ -311,4 +318,8 @@ class _ResetDialogState extends ConsumerState<ResetDialog> {
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
void _resetSection() {
|
||||
ref.read(currentSectionProvider.notifier).setCurrentSection(Section.home);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user