Fixes issue with changing local passcode; disables passcode option for ephemeral sessions.
This commit is contained in:
@@ -26,6 +26,8 @@ class AccountMenu {
|
||||
return authManager.user || passcodeManager.hasPasscode();
|
||||
}
|
||||
|
||||
$scope.canAddPasscode = !authManager.isEphemeralSession();
|
||||
|
||||
$scope.syncStatus = syncManager.syncStatus;
|
||||
$scope.newPasswordData = {};
|
||||
|
||||
|
||||
@@ -73,7 +73,10 @@ class StorageManager {
|
||||
}
|
||||
|
||||
this.itemsStorageMode = mode;
|
||||
this.storage.clear();
|
||||
if(newStorage !== this.storage) {
|
||||
// Only clear if this.storage isn't the same reference as newStorage
|
||||
this.storage.clear();
|
||||
}
|
||||
this.storage = newStorage;
|
||||
|
||||
if(mode == StorageManager.FixedEncrypted) {
|
||||
|
||||
@@ -128,11 +128,15 @@
|
||||
.panel-section
|
||||
%h3.title.panel-row Passcode Lock
|
||||
%div{"ng-if" => "!hasPasscode()"}
|
||||
.panel-row{"ng-if" => "!formData.showPasscodeForm"}
|
||||
.button.info{"ng-click" => "addPasscodeClicked(); $event.stopPropagation();"}
|
||||
.label Add Passcode
|
||||
%div{"ng-if" => "canAddPasscode"}
|
||||
.panel-row{"ng-if" => "!formData.showPasscodeForm"}
|
||||
.button.info{"ng-click" => "addPasscodeClicked(); $event.stopPropagation();"}
|
||||
.label Add Passcode
|
||||
|
||||
%p Add an app passcode to lock the app and encrypt on-device key storage.
|
||||
%p Add an app passcode to lock the app and encrypt on-device key storage.
|
||||
|
||||
%div{"ng-if" => "!canAddPasscode"}
|
||||
%p Adding a passcode is not supported in temporary sessions. Please sign out, then sign back in with the "Stay signed in" option checked.
|
||||
|
||||
%form{"ng-if" => "formData.showPasscodeForm", "ng-submit" => "submitPasscodeForm()"}
|
||||
%input.form-control{:type => 'password', "ng-model" => "formData.passcode", "placeholder" => "Passcode", "sn-autofocus" => "true", "should-focus" => "true"}
|
||||
|
||||
Reference in New Issue
Block a user