Created
May 17, 2016 00:10
-
-
Save robcolburn/3f172e1d4534f69006cb99c2eb17b8bb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/reducers/entities.js b/reducers/entities.js | |
index 3cf689d..764be35 100644 | |
--- a/reducers/entities.js | |
+++ b/reducers/entities.js | |
@@ -87,7 +87,10 @@ function storeVideos(state, { payload }) { | |
} | |
const normalShow = normalizeShow(payload, getRelationship(payload, video, 'show')); | |
newState[normalVideo.id] = normalVideo; | |
- newState[normalShow.id] = normalShow; | |
+ // VideoList may have stale Show entities, do not overwrite | |
+ if (!state[normalShow.id]) { | |
+ newState[normalShow.id] = normalShow; | |
+ } | |
return newState; | |
}, { | |
...state |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment