1
0
mirror of https://github.com/bitwarden/mobile.git synced 2024-11-04 08:50:18 +01:00

Send vaultTimeoutActionChanged event after save (#948)

This commit is contained in:
Kyle Spearrin 2020-06-02 09:50:08 -04:00 committed by GitHub
parent 48e5b1686f
commit 0fcf006484
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -231,13 +231,14 @@ namespace Bit.App.Pages
} }
} }
var selectionOption = _vaultTimeoutActions.FirstOrDefault(o => o.Key == cleanSelection); var selectionOption = _vaultTimeoutActions.FirstOrDefault(o => o.Key == cleanSelection);
if(_vaultTimeoutActionDisplayValue != selectionOption.Key) var changed = _vaultTimeoutActionDisplayValue != selectionOption.Key;
{
_messagingService.Send("vaultTimeoutActionChanged");
}
_vaultTimeoutActionDisplayValue = selectionOption.Key; _vaultTimeoutActionDisplayValue = selectionOption.Key;
await _vaultTimeoutService.SetVaultTimeoutOptionsAsync(GetVaultTimeoutFromKey(_vaultTimeoutDisplayValue), await _vaultTimeoutService.SetVaultTimeoutOptionsAsync(GetVaultTimeoutFromKey(_vaultTimeoutDisplayValue),
selectionOption.Value); selectionOption.Value);
if (changed)
{
_messagingService.Send("vaultTimeoutActionChanged");
}
BuildList(); BuildList();
} }