Remove unnecessary guard clause

- filter returns an empty array, and no notification is created if
  idsOfUsers is an empty array
This commit is contained in:
mattwr18 2020-02-18 22:43:19 +01:00
parent 7fe6fb110b
commit 54caaaaa0a

View File

@ -53,7 +53,6 @@ const postAuthorOfComment = async (commentId, { context }) => {
}
const notifyUsersOfMention = async (label, id, idsOfUsers, reason, context) => {
if (!(idsOfUsers && idsOfUsers.length)) return []
await validateNotifyUsers(label, reason)
let mentionedCypher
switch (reason) {