Merge branch 'master' into rm-immutable-js

This commit is contained in:
Kim Gardner
2017-08-15 11:27:45 +01:00
committed by GitHub
12 changed files with 82 additions and 67 deletions
@@ -26,6 +26,9 @@ export default {
IgnoreUser: ({variables}) => ({
updateQueries: {
CoralEmbedStream_Embed: (previous) => {
if (!previous.asset.featuredComments) {
return previous;
}
const ignoredUserId = variables.id;
const newNodes = previous.asset.featuredComments.nodes.filter((n) => n.user.id !== ignoredUserId);
const removedCount = previous.asset.featuredComments.nodes.length - newNodes.length;