Page MenuHomePhabricator

D4200.diff
No OneTemporary

D4200.diff

diff --git a/lib/reducers/thread-reducer.js b/lib/reducers/thread-reducer.js
--- a/lib/reducers/thread-reducer.js
+++ b/lib/reducers/thread-reducer.js
@@ -219,7 +219,8 @@
action.type === processUpdatesActionType ||
action.type === newThreadActionTypes.success
) {
- if (action.payload.updatesResult.newUpdates.length === 0) {
+ const { newUpdates } = action.payload.updatesResult;
+ if (newUpdates.length === 0) {
return {
threadStore: state,
newThreadInconsistencies: [],
@@ -240,18 +241,19 @@
threadStoreOperations,
};
} else if (action.type === updateSubscriptionActionTypes.success) {
+ const { threadID, subscription } = action.payload;
const newThreadInfo = {
- ...state.threadInfos[action.payload.threadID],
+ ...state.threadInfos[threadID],
currentUser: {
- ...state.threadInfos[action.payload.threadID].currentUser,
- subscription: action.payload.subscription,
+ ...state.threadInfos[threadID].currentUser,
+ subscription,
},
};
const threadStoreOperations = [
{
type: 'replace',
payload: {
- id: action.payload.threadID,
+ id: threadID,
threadInfo: newThreadInfo,
},
},

File Metadata

Mime Type
text/plain
Expires
Sun, Dec 1, 8:50 AM (20 h, 10 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2604459
Default Alt Text
D4200.diff (1 KB)

Event Timeline