Skip to content

Commit

Permalink
Fixed wrong i18n key
Browse files Browse the repository at this point in the history
refs #9519

- `errors.models.posts.postNotFound` -> wrong
- `errors.models.post.postNotFound`  -> correct
- the i18n lib just logs the error and falls back to a valid error key
- wrong i18n keys will never break Ghost
  • Loading branch information
kirrg001 committed Mar 21, 2018
1 parent 1d65581 commit f0c8e3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/server/models/post.js
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ Post = ghostBookshelf.Model.extend({
.then(function then(foundPostModel) {
if (!foundPostModel) {
throw new common.errors.NotFoundError({
message: common.i18n.t('errors.models.posts.postNotFound')
message: common.i18n.t('errors.models.post.postNotFound')
});
}

Expand Down

0 comments on commit f0c8e3c

Please sign in to comment.