Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3399587
D9518.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D9518.diff
View Options
diff --git a/native/redux/persist.js b/native/redux/persist.js
--- a/native/redux/persist.js
+++ b/native/redux/persist.js
@@ -49,6 +49,7 @@
import {
type LocalMessageInfo,
type MessageStore,
+ type MessageStoreThreads,
} from 'lib/types/message-types.js';
import type {
ReportStore,
@@ -815,6 +816,26 @@
},
};
},
+ [54]: state => {
+ let updatedMessageStoreThreads: MessageStoreThreads = {};
+ for (const threadID: string in state.messageStore.threads) {
+ const { lastNavigatedTo, lastPruned, ...rest } =
+ state.messageStore.threads[threadID];
+
+ updatedMessageStoreThreads = {
+ ...updatedMessageStoreThreads,
+ [threadID]: rest,
+ };
+ }
+
+ return {
+ ...state,
+ messageStore: {
+ ...state.messageStore,
+ threads: updatedMessageStoreThreads,
+ },
+ };
+ },
};
// After migration 31, we'll no longer want to persist `messageStore.messages`
@@ -944,7 +965,7 @@
'connection',
],
debug: __DEV__,
- version: 53,
+ version: 54,
transforms: [
messageStoreMessagesBlocklistTransform,
reportStoreTransform,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Dec 3, 3:53 AM (20 h, 54 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2610114
Default Alt Text
D9518.diff (1 KB)
Attached To
Mode
D9518: [native] Redux migration to remove `messageStore.threads[threadID].[lastPruned/lastNavigatedTo]`
Attached
Detach File
Event Timeline
Log In to Comment