0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-20 22:42:53 -05:00

Removed permissible method from setting model

ref ENG-728
ref https://linear.app/tryghost/issue/ENG-728

This implementation is essentially a no-op so we can remove it completely
This commit is contained in:
Fabien O'Carroll 2024-03-20 12:48:01 -04:00 committed by Fabien 'egg' O'Carroll
parent 4c598a1e6d
commit e29c653ef6

View file

@ -324,16 +324,6 @@ Settings = ghostBookshelf.Model.extend({
return allSettings;
},
permissible: function permissible(modelId, action, context, unsafeAttrs, loadedPermissions, hasUserPermission, hasApiKeyPermission) {
if (hasUserPermission && hasApiKeyPermission) {
return Promise.resolve();
}
return Promise.reject(new errors.NoPermissionError({
message: tpl(messages.notEnoughPermission)
}));
},
validators: {
async all(model) {
const settingName = model.get('key');