2
1
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2023-12-13 21:00:40 +01:00

Improved error context usage

refs #10571

- Change was done to avoid usage of hardcoded value and provide more context. Additionally errorDetails are formatted in a readable way
This commit is contained in:
Nazar Gargol 2019-04-23 09:45:11 +02:00
parent 63337dd823
commit cb322fc1be
2 changed files with 2 additions and 2 deletions

View file

@ -54,7 +54,7 @@ themes = {
if (!loadedTheme) {
return Promise.reject(new common.errors.ValidationError({
message: common.i18n.t('notices.data.validation.index.themeCannotBeActivated', {themeName: themeName}),
context: 'active_theme'
errorDetails: newSettings
}));
}

View file

@ -45,7 +45,7 @@ module.exports = {
if (!loadedTheme) {
return Promise.reject(new common.errors.ValidationError({
message: common.i18n.t('notices.data.validation.index.themeCannotBeActivated', {themeName: themeName}),
context: 'active_theme'
errorDetails: newSettings
}));
}