Add support for ACI safety numbers behind a feature flag
This commit is contained in:
parent
42cd8ce792
commit
c1580a5eb3
38 changed files with 1392 additions and 204 deletions
|
@ -2,15 +2,18 @@
|
|||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import { refreshRemoteConfig } from '../../RemoteConfig';
|
||||
import type { WebAPIType } from '../../textsecure/WebAPI';
|
||||
import type { UnwrapPromise } from '../../types/Util';
|
||||
import type {
|
||||
WebAPIType,
|
||||
RemoteConfigResponseType,
|
||||
} from '../../textsecure/WebAPI';
|
||||
import { SECOND } from '../../util/durations';
|
||||
|
||||
export async function updateRemoteConfig(
|
||||
newConfig: UnwrapPromise<ReturnType<WebAPIType['getConfig']>>
|
||||
newConfig: RemoteConfigResponseType['config']
|
||||
): Promise<void> {
|
||||
const fakeServer = {
|
||||
async getConfig() {
|
||||
return newConfig;
|
||||
return { config: newConfig, serverEpochTime: Date.now() / SECOND };
|
||||
},
|
||||
} as Partial<WebAPIType> as unknown as WebAPIType;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue