Skip to content
Snippets Groups Projects
Commit cf756b35 authored by Andrei Cioromila's avatar Andrei Cioromila
Browse files

refactor(notifications): Return the sendEmail promise so the caller can handle it

parent 849d0cbc
No related branches found
No related tags found
3 merge requests!160Update staging with master features,!156Develop,!149Hin 1089
......@@ -88,7 +88,7 @@ The `Email` class also provides a `constructor` whose properties will be used wh
hasSignature: true }
})
email.sendEmail()
return email.sendEmail()
}
```
......
......@@ -47,7 +47,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
sendSignupEmail: ({ user, baseUrl }) => {
const confirmSignUp = config.get('confirm-signup.url')
......@@ -80,6 +80,6 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
}
......@@ -71,7 +71,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
sendEiCEmail: async ({
reason,
......@@ -130,6 +130,6 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
}
......@@ -114,6 +114,6 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
}
......@@ -79,7 +79,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
sendReviewerEmail: async ({
baseUrl,
......@@ -139,6 +139,6 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
}
......@@ -67,7 +67,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyHEWhenEiCMakesDecision() {
......@@ -113,7 +113,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyHEWhenEiCReturnsToHE() {
......@@ -163,7 +163,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyEAWhenEiCMakesFinalDecision() {
......@@ -190,7 +190,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyEAWhenEiCRequestsEQAApproval() {
......@@ -227,7 +227,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyAuthorsWhenEiCMakesDecision() {
......@@ -294,7 +294,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
}
......@@ -354,7 +354,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
}
......@@ -404,7 +404,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
async notifyReviewersWhenHEMakesRecommendation() {
......@@ -464,7 +464,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
}
acceptedReviewers.forEach(
......@@ -544,7 +544,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
}
......@@ -585,7 +585,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
}
......@@ -625,7 +625,7 @@ class Notification {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
}
......
......@@ -53,7 +53,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
async sendReviewersEmail({
......@@ -108,7 +108,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
})
},
......@@ -144,7 +144,7 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
async sendAuthorsEmail({ baseUrl, fragment, UserModel, collection }) {
......@@ -237,7 +237,7 @@ module.exports = {
email.content.ctaText = 'CONFIRM ACCOUNT'
}
email.sendEmail()
return email.sendEmail()
})
},
}
......@@ -37,6 +37,6 @@ module.exports = {
bodyProps,
})
email.sendEmail()
return email.sendEmail()
},
}
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment