mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-24 19:33:02 +03:00
Removed "object" as a valid value for settings type
refs https://github.com/TryGhost/Ghost/issues/10318 - Storing JSON object in settings has caused multiple bugs in the past and was considered an antipattern - This is a last bit in the long process of getting rid of "object" settings in the database. At this point there should be no settings with this type. Yey!
This commit is contained in:
parent
176433e307
commit
ce50653f89
@ -175,6 +175,7 @@ module.exports = {
|
||||
}
|
||||
},
|
||||
key: {type: 'string', maxlength: 50, nullable: false, unique: true},
|
||||
// NOTE: as JSON objects are no longer stored in `value` we could pottentialy reduce the maxlength
|
||||
value: {type: 'text', maxlength: 65535, nullable: true},
|
||||
type: {
|
||||
type: 'string',
|
||||
@ -185,9 +186,7 @@ module.exports = {
|
||||
'array',
|
||||
'string',
|
||||
'number',
|
||||
'boolean',
|
||||
// TODO: `object` type needs to be removed once all existing object settings are removed
|
||||
'object'
|
||||
'boolean'
|
||||
]]
|
||||
}
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user