mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
Fixed incorrect codeinjection_* assignment
no issue - discovered while testing
This commit is contained in:
parent
e109c54245
commit
e79fc9a9be
1 changed files with 6 additions and 6 deletions
|
@ -47,13 +47,13 @@ module.exports.forSettings = (attrs, frame) => {
|
||||||
|
|
||||||
// CASE: edit
|
// CASE: edit
|
||||||
if (frame.original.body && frame.original.body.settings) {
|
if (frame.original.body && frame.original.body.settings) {
|
||||||
frame.original.body.settings.forEach((setting, index) => {
|
frame.original.body.settings.forEach((setting) => {
|
||||||
if (setting.key === 'codeinjection_head') {
|
if (setting.key === 'codeinjection_head') {
|
||||||
attrs[index].key = 'codeinjection_head';
|
const target = _.find(attrs, {key: 'ghost_head'});
|
||||||
}
|
target.key = 'codeinjection_head';
|
||||||
|
} else if (setting.key === 'codeinjection_foot') {
|
||||||
if (setting.key === 'codeinjection_foot') {
|
const target = _.find(attrs, {key: 'ghost_foot'});
|
||||||
attrs[index].key = 'codeinjection_foot';
|
target.key = 'codeinjection_foot';
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue