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

Replaced i18n.t w/ tpl helper in pages-public.js

refs: #13380
This commit is contained in:
Ania Kowalska 2021-10-06 12:47:38 +02:00 committed by Hannah Wolfe
parent 1d534bcd65
commit c38b4ef1f7

View file

@ -1,8 +1,12 @@
const i18n = require('../../../shared/i18n');
const tpl = require('@tryghost/tpl');
const errors = require('@tryghost/errors');
const models = require('../../models');
const ALLOWED_INCLUDES = ['tags', 'authors'];
const messages = {
pageNotFound: 'Page not found.'
};
module.exports = {
docName: 'pages',
@ -63,7 +67,7 @@ module.exports = {
.then((model) => {
if (!model) {
throw new errors.NotFoundError({
message: i18n.t('errors.api.pages.pageNotFound')
message: tpl(messages.pageNotFound)
});
}