From bef3e3e33c55b139c3e3702712dfc045fea1d201 Mon Sep 17 00:00:00 2001 From: Chi Vinh Le Date: Fri, 20 Oct 2017 17:19:44 +0200 Subject: [PATCH] Turn off notifications for flagged and edited --- .../src/routes/Moderation/containers/Moderation.js | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/client/coral-admin/src/routes/Moderation/containers/Moderation.js b/client/coral-admin/src/routes/Moderation/containers/Moderation.js index 8787d77cd..1161ad5dc 100644 --- a/client/coral-admin/src/routes/Moderation/containers/Moderation.js +++ b/client/coral-admin/src/routes/Moderation/containers/Moderation.js @@ -115,17 +115,14 @@ class ModerationContainer extends Component { document: COMMENT_EDITED_SUBSCRIPTION, variables, updateQuery: (prev, {subscriptionData: {data: {commentEdited: comment}}}) => { - const notifyText = t('modqueue.notify_edited', comment.user.username, prepareNotificationText(comment.body)); - return this.handleCommentChange(prev, comment, notifyText); + return this.handleCommentChange(prev, comment); }, }, { document: COMMENT_FLAGGED_SUBSCRIPTION, variables, updateQuery: (prev, {subscriptionData: {data: {commentFlagged: comment}}}) => { - const user = comment.actions[comment.actions.length - 1].user; - const notifyText = t('modqueue.notify_flagged', user.username, prepareNotificationText(comment.body)); - return this.handleCommentChange(prev, comment, notifyText); + return this.handleCommentChange(prev, comment); }, }, ];