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

Updated createEmailBatches JSDoc

refs https://github.com/TryGhost/Team/issues/828

- Updated to follow latest code standards
This commit is contained in:
Naz 2021-06-30 13:56:35 +04:00
parent ed46f31c71
commit 32a09dc9c6

View file

@ -344,10 +344,17 @@ async function getEmailMemberRows({emailModel, options}) {
return memberRows;
}
// Store email_batch and email_recipient records for an email.
// Uses knex directly rather than bookshelf to avoid thousands of bookshelf model
// instantiations and associated processing and event loop blocking.
// Returns array of batch ids
/**
* Store email_batch and email_recipient records for an email.
* Uses knex directly rather than bookshelf to avoid thousands of bookshelf model
* instantiations and associated processing and event loop blocking.
*
* @param {Object} options
* @param {Object} options.emailModel - instance of Email model
* @param {Object} options.options
*
* @returns {Promise<string[]>} - created batch ids
*/
async function createEmailBatches({emailModel, options}) {
const memberRows = await getEmailMemberRows({emailModel, options});