From a93c13306cb98fb69caf85242056258faab27b53 Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Fri, 28 Feb 2020 11:25:04 +0000 Subject: [PATCH] Prefer account password variation of upgrading This shows the account password variation of upgrade encryption first if it's possible to do so. This ensures we match the logic that locks the next button. Fixes https://github.com/vector-im/riot-web/issues/12560 --- .../secretstorage/CreateSecretStorageDialog.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/async-components/views/dialogs/secretstorage/CreateSecretStorageDialog.js b/src/async-components/views/dialogs/secretstorage/CreateSecretStorageDialog.js index 84b94ab64c..08d1e0638b 100644 --- a/src/async-components/views/dialogs/secretstorage/CreateSecretStorageDialog.js +++ b/src/async-components/views/dialogs/secretstorage/CreateSecretStorageDialog.js @@ -400,12 +400,7 @@ export default class CreateSecretStorageDialog extends React.PureComponent { let authPrompt; let nextCaption = _t("Next"); - if (!this.state.backupSigStatus.usable) { - authPrompt =
-
{_t("Restore your key backup to upgrade your encryption")}
-
; - nextCaption = _t("Restore"); - } else if (this.state.canUploadKeysWithPasswordOnly) { + if (this.state.canUploadKeysWithPasswordOnly) { authPrompt =
{_t("Enter your account password to confirm the upgrade:")}
; + } else if (!this.state.backupSigStatus.usable) { + authPrompt =
+
{_t("Restore your key backup to upgrade your encryption")}
+
; + nextCaption = _t("Restore"); } else { authPrompt =

{_t("You'll need to authenticate with the server to confirm the upgrade.")}