Support server-determined build expiration
This commit is contained in:
parent
a04f9a0e51
commit
d87335f5a6
14 changed files with 147 additions and 28 deletions
|
@ -1543,6 +1543,25 @@
|
|||
await window.Signal.RemoteConfig.maybeRefreshRemoteConfig();
|
||||
});
|
||||
|
||||
// Listen for changes to the `desktop.clientExpiration` remote flag
|
||||
window.Signal.RemoteConfig.onChange(
|
||||
'desktop.clientExpiration',
|
||||
({ value }) => {
|
||||
const remoteBuildExpirationTimestamp = window.Signal.Util.parseRemoteClientExpiration(
|
||||
value
|
||||
);
|
||||
if (remoteBuildExpirationTimestamp) {
|
||||
window.storage.put(
|
||||
'remoteBuildExpiration',
|
||||
remoteBuildExpirationTimestamp
|
||||
);
|
||||
window.reduxActions.expiration.hydrateExpirationStatus(
|
||||
window.Signal.Util.hasExpired()
|
||||
);
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
// Listen for changes to the `desktop.messageRequests` remote configuration flag
|
||||
const removeMessageRequestListener = window.Signal.RemoteConfig.onChange(
|
||||
'desktop.messageRequests',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue