mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-01 13:54:35 +03:00
replaced i18n with tpl in mega of core services (#13546)
refs: #13380 - The i18n package is deprecated. It is being replaced with the tpl package. Co-authored-by: jack.wu <jack.wu@wemoscooter.com>
This commit is contained in:
parent
c5459db52e
commit
65d5b8d671
@ -6,7 +6,6 @@ const url = require('url');
|
||||
const moment = require('moment');
|
||||
const ObjectID = require('bson-objectid');
|
||||
const errors = require('@tryghost/errors');
|
||||
const i18n = require('../../../shared/i18n');
|
||||
const logging = require('@tryghost/logging');
|
||||
const settingsCache = require('../../../shared/settings-cache');
|
||||
const membersService = require('../members');
|
||||
@ -25,7 +24,8 @@ const messages = {
|
||||
invalidSegment: 'Invalid segment value. Use one of the valid:"status:free" or "status:-free" values.',
|
||||
unexpectedFilterError: 'Unexpected {property} value "{value}", expected an NQL equivalent',
|
||||
noneFilterError: 'Cannot send email to "none" {property}',
|
||||
emailSendingDisabled: `Email sending is temporarily disabled because your account is currently in review. You should have an email about this from us already, but you can also reach us any time at support@ghost.org`
|
||||
emailSendingDisabled: `Email sending is temporarily disabled because your account is currently in review. You should have an email about this from us already, but you can also reach us any time at support@ghost.org`,
|
||||
sendEmailRequestFailed: 'The email service was unable to send an email batch.'
|
||||
};
|
||||
|
||||
const getFromAddress = () => {
|
||||
@ -354,7 +354,7 @@ async function sendEmailJob({emailModel, options}) {
|
||||
|
||||
throw new errors.GhostError({
|
||||
err: error,
|
||||
context: i18n.t('errors.services.mega.requestFailed.error')
|
||||
context: tpl(messages.sendEmailRequestFailed)
|
||||
});
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user