Remove global dependency on notification on admin

This commit is contained in:
Chi Vinh Le
2017-08-23 03:48:20 +07:00
parent 89037a2e05
commit a23bad49c6
6 changed files with 50 additions and 52 deletions
@@ -21,14 +21,14 @@ class ModSubscription extends React.Component {
assetId: this.props.data.variables.asset_id,
},
updateQuery: (prev, {subscriptionData: {data: {commentFeatured: {user, comment}}}}) => {
const notify = this.props.user.id === user.id
const notifyText = this.props.user.id === user.id
? ''
: t(
'talk-plugin-featured-comments.notify_featured',
user.username,
prepareNotificationText(comment.body),
);
return this.props.handleCommentChange(prev, comment, notify);
return this.props.handleCommentChange(prev, comment, notifyText);
},
},
{