0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00

Added missing await statement

no issue

- The 90905b0212 refactor missed the statment which is causing email to not being sent
This commit is contained in:
Nazar Gargol 2019-11-27 09:39:48 +07:00
parent 90905b0212
commit 63e6dd59fa

View file

@ -61,7 +61,7 @@ const addEmail = async (postModel, options) => {
.findAll(Object.assign({filter: 'subscribed:true'}, knexOptions))
.map(member => member.toJSON(options));
const {emailTmpl, emails} = getEmailData(postModel, members);
const {emailTmpl, emails} = await getEmailData(postModel, members);
// NOTE: don't create email object when there's nobody to send the email to
if (!emails.length) {