createComment and suspect list

This commit is contained in:
Belen Curcio
2017-01-20 16:47:02 -03:00
6 changed files with 58 additions and 135 deletions
+1 -1
View File
@@ -118,7 +118,7 @@ const createPublicComment = (context, commentInput) => {
// If the comment was flagged as being suspect, we need to add a
// flag to it to indicate that it needs to be looked at.
// Otherwise just return the new comment.
if (wordlist.suspect) {
if (wordlist != null && wordlist.suspect) {
// TODO: this is kind of fragile, we should refactor this to resolve
// all these const's that we're using like 'comments', 'flag' to be