mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-25 20:03:12 +03:00
Reduced error level to default for not found post error
refs #12064
- `critical` is meant to be something unpredictable like internal error, something worthy attention, as described in Ignition -3439456d94/README.md (list-of-errors)
- This error level was introduced with - this PR https://github.com/TryGhost/Ghost/pull/9426, but there is no context provided why this specific value was used. Assuming it's an outdated value as 'not found' is nowhere to be treated in any special way
This commit is contained in:
parent
1b449f4f53
commit
b76a6a1eee
@ -353,7 +353,6 @@ module.exports.extendModel = function extendModel(Post, Posts, ghostBookshelf) {
|
|||||||
.then(function then(foundPostModel) {
|
.then(function then(foundPostModel) {
|
||||||
if (!foundPostModel) {
|
if (!foundPostModel) {
|
||||||
throw new errors.NotFoundError({
|
throw new errors.NotFoundError({
|
||||||
level: 'critical',
|
|
||||||
message: i18n.t('errors.models.post.postNotFound')
|
message: i18n.t('errors.models.post.postNotFound')
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user