Introduce isStagingServer util method
This commit is contained in:
parent
4cdb6fab08
commit
cd44a7a033
24 changed files with 80 additions and 71 deletions
|
@ -2,14 +2,10 @@
|
|||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import * as RemoteConfig from '../RemoteConfig';
|
||||
import { Environment, getEnvironment } from '../environment';
|
||||
import { isStaging } from './version';
|
||||
import { isStagingServer } from './isStagingServer';
|
||||
|
||||
export function isBackupEnabled(): boolean {
|
||||
if (getEnvironment() === Environment.Staging) {
|
||||
return true;
|
||||
}
|
||||
if (isStaging(window.getVersion())) {
|
||||
if (isStagingServer()) {
|
||||
return true;
|
||||
}
|
||||
return Boolean(RemoteConfig.isEnabled('desktop.backup.credentialFetch'));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue