mirror of
https://github.com/element-hq/element-web
synced 2024-11-24 18:25:49 +03:00
Merge pull request #4701 from matrix-org/bwindels/preventbootstrapfromkeybackuprestore
Prevent (double) 4S bootstrap from RestoreKeyBackupDialog
This commit is contained in:
commit
77b012e49b
1 changed files with 4 additions and 2 deletions
|
@ -227,8 +227,10 @@ export default class RestoreKeyBackupDialog extends React.PureComponent {
|
||||||
loadError: null,
|
loadError: null,
|
||||||
});
|
});
|
||||||
try {
|
try {
|
||||||
const backupInfo = await MatrixClientPeg.get().getKeyBackupVersion();
|
const cli = MatrixClientPeg.get();
|
||||||
const backupKeyStored = await MatrixClientPeg.get().isKeyBackupKeyStored();
|
const backupInfo = await cli.getKeyBackupVersion();
|
||||||
|
const has4S = await cli.hasSecretStorageKey();
|
||||||
|
const backupKeyStored = has4S && await cli.isKeyBackupKeyStored();
|
||||||
this.setState({
|
this.setState({
|
||||||
backupInfo,
|
backupInfo,
|
||||||
backupKeyStored,
|
backupKeyStored,
|
||||||
|
|
Loading…
Reference in a new issue