diff --git a/ts/RemoteConfig.ts b/ts/RemoteConfig.ts index 09853316c..65fb26265 100644 --- a/ts/RemoteConfig.ts +++ b/ts/RemoteConfig.ts @@ -13,7 +13,7 @@ export type ConfigKeyType = | 'desktop.mandatoryProfileSharing' | 'desktop.messageRequests' | 'desktop.storage' - | 'desktop.storageWrite2' + | 'desktop.storageWrite3' | 'global.groupsv2.maxGroupSize' | 'global.groupsv2.groupSizeHardLimit'; type ConfigValueType = { diff --git a/ts/models/conversations.ts b/ts/models/conversations.ts index ade463f40..c14452a79 100644 --- a/ts/models/conversations.ts +++ b/ts/models/conversations.ts @@ -4895,9 +4895,9 @@ export class ConversationModel extends window.Backbone.Model< // [X] archived // [X] markedUnread captureChange(logMessage: string): void { - if (!window.Signal.RemoteConfig.isEnabled('desktop.storageWrite2')) { + if (!window.Signal.RemoteConfig.isEnabled('desktop.storageWrite3')) { window.log.info( - 'conversation.captureChange: Returning early; desktop.storageWrite2 is falsey' + 'conversation.captureChange: Returning early; desktop.storageWrite3 is falsey' ); return; diff --git a/ts/services/storage.ts b/ts/services/storage.ts index 053aab740..cd21ceb44 100644 --- a/ts/services/storage.ts +++ b/ts/services/storage.ts @@ -127,6 +127,8 @@ async function generateManifest( isNewManifest ); + await window.ConversationController.checkForConflicts(); + const ITEM_TYPE = window.textsecure.protobuf.ManifestRecord.Identifier.Type; const conversationsToUpdate = []; diff --git a/ts/storage/isFeatureEnabled.ts b/ts/storage/isFeatureEnabled.ts index 7cc7b1293..0874e84a0 100644 --- a/ts/storage/isFeatureEnabled.ts +++ b/ts/storage/isFeatureEnabled.ts @@ -8,5 +8,5 @@ function isStorageFeatureEnabled(): boolean { } export function isStorageWriteFeatureEnabled(): boolean { - return isStorageFeatureEnabled() && isEnabled('desktop.storageWrite2'); + return isStorageFeatureEnabled() && isEnabled('desktop.storageWrite3'); } diff --git a/ts/test-node/components/leftPane/LeftPaneComposeHelper_test.ts b/ts/test-node/components/leftPane/LeftPaneComposeHelper_test.ts index a17d3f930..342764cf1 100644 --- a/ts/test-node/components/leftPane/LeftPaneComposeHelper_test.ts +++ b/ts/test-node/components/leftPane/LeftPaneComposeHelper_test.ts @@ -27,7 +27,7 @@ describe('LeftPaneComposeHelper', () => { .stub(remoteConfig, 'isEnabled') .withArgs('desktop.storage') .returns(true) - .withArgs('desktop.storageWrite2') + .withArgs('desktop.storageWrite3') .returns(true); }); @@ -143,7 +143,7 @@ describe('LeftPaneComposeHelper', () => { remoteConfigStub .withArgs('desktop.storage') .returns(false) - .withArgs('desktop.storageWrite2') + .withArgs('desktop.storageWrite3') .returns(false); assert.isUndefined( @@ -157,7 +157,7 @@ describe('LeftPaneComposeHelper', () => { remoteConfigStub .withArgs('desktop.storage') .returns(true) - .withArgs('desktop.storageWrite2') + .withArgs('desktop.storageWrite3') .returns(false); assert.isUndefined(