From ae963349d9b7c7e0d079fbeac5d3ab66130af4f8 Mon Sep 17 00:00:00 2001 From: Tomasz Palys Date: Fri, 8 Nov 2024 17:47:35 +0100 Subject: [PATCH] [lib] Introduce a restore flow flag Summary: This flag is used to decide if we show the restore button. https://linear.app/comm/issue/ENG-9679/create-a-screen-where-user-can-choose-between-usernamepassword-and Test Plan: Flow Reviewers: kamil, angelika, bartek Reviewed By: kamil Subscribers: ashoat Differential Revision: https://phab.comm.dev/D13905 --- lib/utils/services-utils.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/utils/services-utils.js b/lib/utils/services-utils.js index c22609665e..93e0a30470 100644 --- a/lib/utils/services-utils.js +++ b/lib/utils/services-utils.js @@ -18,6 +18,11 @@ const supportingMultipleKeyservers = false; // an authoritative keyserver for things like DMs. const relyingOnAuthoritativeKeyserver = true; +// If this is true, then we're using the login 2.0, which means that a user +// can either restore an account (primary login) or log in using the QR code +// (secondary login). +const usingRestoreFlow = false; + function handleHTTPResponseError(response: Response): void { if (!response.ok) { const { status, statusText } = response; @@ -47,6 +52,7 @@ export { usingCommServicesAccessToken, supportingMultipleKeyservers, relyingOnAuthoritativeKeyserver, + usingRestoreFlow, createHTTPAuthorizationHeader, createDefaultHTTPRequestHeaders, };