WIP
This commit is contained in:
@@ -59,19 +59,27 @@ class AccountMenuCtrl extends PureCtrl {
|
||||
},
|
||||
mutable: {}
|
||||
};
|
||||
application.onReady(() => {
|
||||
this.setState({
|
||||
user: this.application.getUser(),
|
||||
canAddPasscode: !this.application.isEphemeralSession(),
|
||||
});
|
||||
application.onReady(async () => {
|
||||
this.setState(await this.refreshedCredentialState());
|
||||
this.loadHost();
|
||||
this.checkForSecurityUpdate();
|
||||
this.reloadAutoLockInterval();
|
||||
this.loadBackupsAvailability();
|
||||
});
|
||||
application.onCredentialChange(async () => {
|
||||
this.setState(await this.refreshedCredentialState());
|
||||
});
|
||||
this.syncStatus = this.application.getSyncStatus();
|
||||
}
|
||||
|
||||
async refreshedCredentialState() {
|
||||
return {
|
||||
user: this.application.getUser(),
|
||||
canAddPasscode: !this.application.isEphemeralSession(),
|
||||
hasPasscode: await this.application.hasPasscode()
|
||||
};
|
||||
}
|
||||
|
||||
$onInit() {
|
||||
this.initProps({
|
||||
closeFunction: this.closeFunction
|
||||
@@ -473,10 +481,6 @@ class AccountMenuCtrl extends PureCtrl {
|
||||
}
|
||||
}
|
||||
|
||||
hasPasscode() {
|
||||
return this.application.hasPasscode();
|
||||
}
|
||||
|
||||
addPasscodeClicked() {
|
||||
this.setFormDataState({
|
||||
showPasscodeForm: true
|
||||
|
||||
Reference in New Issue
Block a user