mirror of
https://github.com/bitwarden/mobile
synced 2026-01-08 19:43:56 +00:00
catch EnableForegroundDispatch exception. disable
back button on yubikey 2fa.
This commit is contained in:
@@ -335,6 +335,17 @@ namespace Bit.App.Pages
|
||||
MessagingCenter.Unsubscribe<Application>(Application.Current, "ResumeYubiKey");
|
||||
}
|
||||
|
||||
protected override bool OnBackButtonPressed()
|
||||
{
|
||||
// ref: https://github.com/bitwarden/mobile/issues/350
|
||||
if(Device.RuntimePlatform == Device.Android && _providerType.HasValue &&
|
||||
_providerType.Value == TwoFactorProviderType.YubiKey)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return base.OnBackButtonPressed();
|
||||
}
|
||||
|
||||
private async void AnotherMethodAsync()
|
||||
{
|
||||
var beforeProviderType = _providerType;
|
||||
|
||||
Reference in New Issue
Block a user