ghost 6.0.1 → 6.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (21) hide show
  1. package/components/tryghost-i18n-6.0.3.tgz +0 -0
  2. package/core/built/admin/assets/admin-x-activitypub/admin-x-activitypub.js +1 -1
  3. package/core/built/admin/assets/admin-x-activitypub/{index-WIpRkbBf.mjs → index-BGpQ-bIj.mjs} +2 -2
  4. package/core/built/admin/assets/admin-x-activitypub/{index-CDrRmlpe.mjs → index-DzkhcDJy.mjs} +2529 -2508
  5. package/core/built/admin/assets/admin-x-settings/{CodeEditorView-9qhoUeVL.mjs → CodeEditorView-CFP3ZKm2.mjs} +2 -2
  6. package/core/built/admin/assets/admin-x-settings/admin-x-settings.js +1 -1
  7. package/core/built/admin/assets/admin-x-settings/{index-CnakDjsf.mjs → index-CNPz6XrY.mjs} +2 -2
  8. package/core/built/admin/assets/admin-x-settings/{index-BzxJK9GM.mjs → index-qJnVka7B.mjs} +4 -4
  9. package/core/built/admin/assets/admin-x-settings/{modals-BHwWDshH.mjs → modals-CZ910p4i.mjs} +4 -4
  10. package/core/built/admin/assets/{chunk.524.54926af287de331c1ed0.js → chunk.524.9820d2bf73b62bb7dba9.js} +7 -7
  11. package/core/built/admin/assets/{chunk.582.343ddc9811a43f00de93.js → chunk.582.0ed287001a73163b5634.js} +8 -8
  12. package/core/built/admin/index.html +2 -2
  13. package/core/frontend/web/middleware/redirect-ghost-to-admin.js +8 -5
  14. package/core/server/api/endpoints/previews.js +1 -0
  15. package/core/server/api/endpoints/utils/index.js +9 -0
  16. package/core/server/api/endpoints/utils/serializers/output/utils/clean.js +3 -1
  17. package/core/server/data/migrations/utils/schema.js +97 -1
  18. package/package.json +6 -6
  19. package/tsconfig.tsbuildinfo +1 -1
  20. package/yarn.lock +35 -22
  21. package/components/tryghost-i18n-6.0.1.tgz +0 -0
@@ -1,11 +1,11 @@
1
- var __ember_auto_import__;(()=>{var e,r={15263:function(e,r){window._eai_r=require,window._eai_d=define},31048:()=>{},32186:e=>{"use strict"
2
- e.exports=require("@ember/test-waiters")},36714:(e,r,t)=>{e.exports=function(){var e=_eai_d,r=_eai_r
3
- function n(e){return e&&e.__esModule?e:Object.assign({default:e},e)}window.emberAutoImportDynamic=function(e){return 1===arguments.length?r("_eai_dyn_"+e):r("_eai_dynt_"+e)(Array.prototype.slice.call(arguments,1))},window.emberAutoImportSync=function(e){return r("_eai_sync_"+e)(Array.prototype.slice.call(arguments,1))},e("@sentry/browser",EAI_DISCOVERED_EXTERNALS("@sentry/browser"),function(){return n(t(32314))}),e("@sentry/core",EAI_DISCOVERED_EXTERNALS("@sentry/core"),function(){return n(t(67723))}),e("@sentry/integrations",EAI_DISCOVERED_EXTERNALS("@sentry/integrations"),function(){return n(t(20080))}),e("@sentry/replay",EAI_DISCOVERED_EXTERNALS("@sentry/replay"),function(){return n(t(51633))}),e("@sentry/utils",EAI_DISCOVERED_EXTERNALS("@sentry/utils"),function(){return n(t(5423))}),e("@tryghost/color-utils",EAI_DISCOVERED_EXTERNALS("@tryghost/color-utils"),function(){return n(t(86797))}),e("@tryghost/kg-clean-basic-html",EAI_DISCOVERED_EXTERNALS("@tryghost/kg-clean-basic-html"),function(){return n(t(3414))}),e("@tryghost/kg-converters",EAI_DISCOVERED_EXTERNALS("@tryghost/kg-converters"),function(){return n(t(23075))}),e("@tryghost/limit-service",EAI_DISCOVERED_EXTERNALS("@tryghost/limit-service"),function(){return n(t(55983))}),e("@tryghost/members-csv/lib/unparse",EAI_DISCOVERED_EXTERNALS("@tryghost/members-csv/lib/unparse"),function(){return n(t(17246))}),e("@tryghost/nql",EAI_DISCOVERED_EXTERNALS("@tryghost/nql"),function(){return n(t(39365))}),e("@tryghost/nql-lang",EAI_DISCOVERED_EXTERNALS("@tryghost/nql-lang"),function(){return n(t(716))}),e("@tryghost/string",EAI_DISCOVERED_EXTERNALS("@tryghost/string"),function(){return n(t(96107))}),e("@tryghost/timezone-data",EAI_DISCOVERED_EXTERNALS("@tryghost/timezone-data"),function(){return n(t(27019))}),e("animejs/lib/anime.es.js",EAI_DISCOVERED_EXTERNALS("animejs/lib/anime.es.js"),function(){return n(t(62282))}),e("element-resize-detector",EAI_DISCOVERED_EXTERNALS("element-resize-detector"),function(){return n(t(29540))}),e("ember-assign-helper/helpers/assign",EAI_DISCOVERED_EXTERNALS("ember-assign-helper/helpers/assign"),function(){return n(t(31113))}),e("ember-css-transitions/modifiers/css-transition",EAI_DISCOVERED_EXTERNALS("ember-css-transitions/modifiers/css-transition"),function(){return n(t(95895))}),e("ember-keyboard/helpers/if-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/helpers/if-key.js"),function(){return n(t(10530))}),e("ember-keyboard/helpers/on-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/helpers/on-key.js"),function(){return n(t(13692))}),e("ember-keyboard/modifiers/on-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/modifiers/on-key.js"),function(){return n(t(40985))}),e("ember-keyboard/services/keyboard.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/services/keyboard.js"),function(){return n(t(89697))}),e("ember-modifier",EAI_DISCOVERED_EXTERNALS("ember-modifier"),function(){return n(t(37777))}),e("ember-moment/helpers/-base",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/-base"),function(){return n(t(91366))}),e("ember-moment/helpers/is-after",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-after"),function(){return n(t(91461))}),e("ember-moment/helpers/is-before",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-before"),function(){return n(t(61e3))}),e("ember-moment/helpers/is-between",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-between"),function(){return n(t(447))}),e("ember-moment/helpers/is-same",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same"),function(){return n(t(64193))}),e("ember-moment/helpers/is-same-or-after",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same-or-after"),function(){return n(t(7916))}),e("ember-moment/helpers/is-same-or-before",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same-or-before"),function(){return n(t(54351))}),e("ember-moment/helpers/moment",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment"),function(){return n(t(41678))}),e("ember-moment/helpers/moment-add",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-add"),function(){return n(t(50080))}),e("ember-moment/helpers/moment-calendar",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-calendar"),function(){return n(t(96625))}),e("ember-moment/helpers/moment-diff",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-diff"),function(){return n(t(85340))}),e("ember-moment/helpers/moment-duration",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-duration"),function(){return n(t(42967))}),e("ember-moment/helpers/moment-format",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-format"),function(){return n(t(10536))}),e("ember-moment/helpers/moment-from",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-from"),function(){return n(t(50727))}),e("ember-moment/helpers/moment-from-now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-from-now"),function(){return n(t(706))}),e("ember-moment/helpers/moment-subtract",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-subtract"),function(){return n(t(54651))}),e("ember-moment/helpers/moment-to",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to"),function(){return n(t(84818))}),e("ember-moment/helpers/moment-to-date",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to-date"),function(){return n(t(81183))}),e("ember-moment/helpers/moment-to-now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to-now"),function(){return n(t(17083))}),e("ember-moment/helpers/now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/now"),function(){return n(t(34980))}),e("ember-moment/helpers/unix",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/unix"),function(){return n(t(79272))}),e("ember-moment/helpers/utc",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/utc"),function(){return n(t(36022))}),e("ember-moment/services/moment",EAI_DISCOVERED_EXTERNALS("ember-moment/services/moment"),function(){return n(t(39879))}),e("fast-deep-equal",EAI_DISCOVERED_EXTERNALS("fast-deep-equal"),function(){return n(t(25383))}),e("flexsearch",EAI_DISCOVERED_EXTERNALS("flexsearch"),function(){return n(t(12248))}),e("focus-trap",EAI_DISCOVERED_EXTERNALS("focus-trap"),function(){return n(t(39632))}),e("intersection-observer-admin",EAI_DISCOVERED_EXTERNALS("intersection-observer-admin"),function(){return n(t(21431))}),e("microdiff",EAI_DISCOVERED_EXTERNALS("microdiff"),function(){return n(t(59086))}),e("moment-timezone",EAI_DISCOVERED_EXTERNALS("moment-timezone"),function(){return n(t(41101))}),e("papaparse",EAI_DISCOVERED_EXTERNALS("papaparse"),function(){return n(t(78695))}),e("raf-pool",EAI_DISCOVERED_EXTERNALS("raf-pool"),function(){return n(t(60695))}),e("react",EAI_DISCOVERED_EXTERNALS("react"),function(){return n(t(72854))}),e("react-dom",EAI_DISCOVERED_EXTERNALS("react-dom"),function(){return n(t(95303))}),e("react-dom/client",EAI_DISCOVERED_EXTERNALS("react-dom/client"),function(){return n(t(70816))}),e("semver/functions/coerce",EAI_DISCOVERED_EXTERNALS("semver/functions/coerce"),function(){return n(t(18576))}),e("semver/functions/lt",EAI_DISCOVERED_EXTERNALS("semver/functions/lt"),function(){return n(t(32817))}),e("semver/functions/parse",EAI_DISCOVERED_EXTERNALS("semver/functions/parse"),function(){return n(t(47898))}),e("tooltip.js",EAI_DISCOVERED_EXTERNALS("tooltip.js"),function(){return n(t(85557))}),e("tracked-built-ins",EAI_DISCOVERED_EXTERNALS("tracked-built-ins"),function(){return n(t(67708))}),e("validator",EAI_DISCOVERED_EXTERNALS("validator"),function(){return n(t(29119))}),e("_eai_dyn_@sentry/browser",[],function(){return Promise.resolve().then(t.bind(t,32314))})}()},56857:(e,r,t)=>{var n={"./af":58547,"./af.js":58547,"./ar":28167,"./ar-dz":35298,"./ar-dz.js":35298,"./ar-kw":11314,"./ar-kw.js":11314,"./ar-ly":66455,"./ar-ly.js":66455,"./ar-ma":15998,"./ar-ma.js":15998,"./ar-sa":55388,"./ar-sa.js":55388,"./ar-tn":73358,"./ar-tn.js":73358,"./ar.js":28167,"./az":92367,"./az.js":92367,"./be":9161,"./be.js":9161,"./bg":359,"./bg.js":359,"./bm":32625,"./bm.js":32625,"./bn":52984,"./bn.js":52984,"./bo":87343,"./bo.js":87343,"./br":87948,"./br.js":87948,"./bs":88211,"./bs.js":88211,"./ca":34700,"./ca.js":34700,"./cs":27430,"./cs.js":27430,"./cv":55913,"./cv.js":55913,"./cy":16004,"./cy.js":16004,"./da":26839,"./da.js":26839,"./de":22131,"./de-at":6729,"./de-at.js":6729,"./de-ch":74743,"./de-ch.js":74743,"./de.js":22131,"./dv":14598,"./dv.js":14598,"./el":38737,"./el.js":38737,"./en-SG":94978,"./en-SG.js":94978,"./en-au":22606,"./en-au.js":22606,"./en-ca":60052,"./en-ca.js":60052,"./en-gb":17305,"./en-gb.js":17305,"./en-ie":76390,"./en-ie.js":76390,"./en-il":89549,"./en-il.js":89549,"./en-nz":67584,"./en-nz.js":67584,"./eo":24408,"./eo.js":24408,"./es":45644,"./es-do":21888,"./es-do.js":21888,"./es-us":23537,"./es-us.js":23537,"./es.js":45644,"./et":27257,"./et.js":27257,"./eu":57002,"./eu.js":57002,"./fa":90241,"./fa.js":90241,"./fi":74009,"./fi.js":74009,"./fo":81267,"./fo.js":81267,"./fr":71160,"./fr-ca":39433,"./fr-ca.js":39433,"./fr-ch":20130,"./fr-ch.js":20130,"./fr.js":71160,"./fy":20553,"./fy.js":20553,"./ga":18232,"./ga.js":18232,"./gd":33771,"./gd.js":33771,"./gl":99747,"./gl.js":99747,"./gom-latn":80289,"./gom-latn.js":80289,"./gu":148,"./gu.js":148,"./he":68247,"./he.js":68247,"./hi":39835,"./hi.js":39835,"./hr":69734,"./hr.js":69734,"./hu":40999,"./hu.js":40999,"./hy-am":95002,"./hy-am.js":95002,"./id":23021,"./id.js":23021,"./is":96232,"./is.js":96232,"./it":15581,"./it-ch":4809,"./it-ch.js":4809,"./it.js":15581,"./ja":45981,"./ja.js":45981,"./jv":12568,"./jv.js":12568,"./ka":17924,"./ka.js":17924,"./kk":1062,"./kk.js":1062,"./km":65456,"./km.js":65456,"./kn":15817,"./kn.js":15817,"./ko":45306,"./ko.js":45306,"./ku":39016,"./ku.js":39016,"./ky":71308,"./ky.js":71308,"./lb":67330,"./lb.js":67330,"./lo":18949,"./lo.js":18949,"./lt":58804,"./lt.js":58804,"./lv":47006,"./lv.js":47006,"./me":83346,"./me.js":83346,"./mi":630,"./mi.js":630,"./mk":88876,"./mk.js":88876,"./ml":86841,"./ml.js":86841,"./mn":93847,"./mn.js":93847,"./mr":57515,"./mr.js":57515,"./ms":51844,"./ms-my":44391,"./ms-my.js":44391,"./ms.js":51844,"./mt":81969,"./mt.js":81969,"./my":34982,"./my.js":34982,"./nb":41632,"./nb.js":41632,"./ne":81781,"./ne.js":81781,"./nl":14910,"./nl-be":72506,"./nl-be.js":72506,"./nl.js":14910,"./nn":12980,"./nn.js":12980,"./pa-in":33791,"./pa-in.js":33791,"./pl":1872,"./pl.js":1872,"./pt":9064,"./pt-br":85273,"./pt-br.js":85273,"./pt.js":9064,"./ro":63167,"./ro.js":63167,"./ru":28649,"./ru.js":28649,"./sd":14823,"./sd.js":14823,"./se":90672,"./se.js":90672,"./si":26244,"./si.js":26244,"./sk":40654,"./sk.js":40654,"./sl":44335,"./sl.js":44335,"./sq":79116,"./sq.js":79116,"./sr":60693,"./sr-cyrl":1436,"./sr-cyrl.js":1436,"./sr.js":60693,"./ss":51734,"./ss.js":51734,"./sv":37945,"./sv.js":37945,"./sw":41514,"./sw.js":41514,"./ta":1991,"./ta.js":1991,"./te":95011,"./te.js":95011,"./tet":19463,"./tet.js":19463,"./tg":43109,"./tg.js":43109,"./th":97144,"./th.js":97144,"./tl-ph":70401,"./tl-ph.js":70401,"./tlh":26678,"./tlh.js":26678,"./tr":28682,"./tr.js":28682,"./tzl":59084,"./tzl.js":59084,"./tzm":64307,"./tzm-latn":68869,"./tzm-latn.js":68869,"./tzm.js":64307,"./ug-cn":78812,"./ug-cn.js":78812,"./uk":25812,"./uk.js":25812,"./ur":25411,"./ur.js":25411,"./uz":59435,"./uz-latn":94589,"./uz-latn.js":94589,"./uz.js":59435,"./vi":50569,"./vi.js":50569,"./x-pseudo":85241,"./x-pseudo.js":85241,"./yo":96972,"./yo.js":96972,"./zh-cn":18422,"./zh-cn.js":18422,"./zh-hk":84106,"./zh-hk.js":84106,"./zh-tw":69362,"./zh-tw.js":69362}
1
+ var __ember_auto_import__;(()=>{var e,r={31048:()=>{},32186:e=>{"use strict"
2
+ e.exports=require("@ember/test-waiters")},56857:(e,r,t)=>{var n={"./af":58547,"./af.js":58547,"./ar":28167,"./ar-dz":35298,"./ar-dz.js":35298,"./ar-kw":11314,"./ar-kw.js":11314,"./ar-ly":66455,"./ar-ly.js":66455,"./ar-ma":15998,"./ar-ma.js":15998,"./ar-sa":55388,"./ar-sa.js":55388,"./ar-tn":73358,"./ar-tn.js":73358,"./ar.js":28167,"./az":92367,"./az.js":92367,"./be":9161,"./be.js":9161,"./bg":359,"./bg.js":359,"./bm":32625,"./bm.js":32625,"./bn":52984,"./bn.js":52984,"./bo":87343,"./bo.js":87343,"./br":87948,"./br.js":87948,"./bs":88211,"./bs.js":88211,"./ca":34700,"./ca.js":34700,"./cs":27430,"./cs.js":27430,"./cv":55913,"./cv.js":55913,"./cy":16004,"./cy.js":16004,"./da":26839,"./da.js":26839,"./de":22131,"./de-at":6729,"./de-at.js":6729,"./de-ch":74743,"./de-ch.js":74743,"./de.js":22131,"./dv":14598,"./dv.js":14598,"./el":38737,"./el.js":38737,"./en-SG":94978,"./en-SG.js":94978,"./en-au":22606,"./en-au.js":22606,"./en-ca":60052,"./en-ca.js":60052,"./en-gb":17305,"./en-gb.js":17305,"./en-ie":76390,"./en-ie.js":76390,"./en-il":89549,"./en-il.js":89549,"./en-nz":67584,"./en-nz.js":67584,"./eo":24408,"./eo.js":24408,"./es":45644,"./es-do":21888,"./es-do.js":21888,"./es-us":23537,"./es-us.js":23537,"./es.js":45644,"./et":27257,"./et.js":27257,"./eu":57002,"./eu.js":57002,"./fa":90241,"./fa.js":90241,"./fi":74009,"./fi.js":74009,"./fo":81267,"./fo.js":81267,"./fr":71160,"./fr-ca":39433,"./fr-ca.js":39433,"./fr-ch":20130,"./fr-ch.js":20130,"./fr.js":71160,"./fy":20553,"./fy.js":20553,"./ga":18232,"./ga.js":18232,"./gd":33771,"./gd.js":33771,"./gl":99747,"./gl.js":99747,"./gom-latn":80289,"./gom-latn.js":80289,"./gu":148,"./gu.js":148,"./he":68247,"./he.js":68247,"./hi":39835,"./hi.js":39835,"./hr":69734,"./hr.js":69734,"./hu":40999,"./hu.js":40999,"./hy-am":95002,"./hy-am.js":95002,"./id":23021,"./id.js":23021,"./is":96232,"./is.js":96232,"./it":15581,"./it-ch":4809,"./it-ch.js":4809,"./it.js":15581,"./ja":45981,"./ja.js":45981,"./jv":12568,"./jv.js":12568,"./ka":17924,"./ka.js":17924,"./kk":1062,"./kk.js":1062,"./km":65456,"./km.js":65456,"./kn":15817,"./kn.js":15817,"./ko":45306,"./ko.js":45306,"./ku":39016,"./ku.js":39016,"./ky":71308,"./ky.js":71308,"./lb":67330,"./lb.js":67330,"./lo":18949,"./lo.js":18949,"./lt":58804,"./lt.js":58804,"./lv":47006,"./lv.js":47006,"./me":83346,"./me.js":83346,"./mi":630,"./mi.js":630,"./mk":88876,"./mk.js":88876,"./ml":86841,"./ml.js":86841,"./mn":93847,"./mn.js":93847,"./mr":57515,"./mr.js":57515,"./ms":51844,"./ms-my":44391,"./ms-my.js":44391,"./ms.js":51844,"./mt":81969,"./mt.js":81969,"./my":34982,"./my.js":34982,"./nb":41632,"./nb.js":41632,"./ne":81781,"./ne.js":81781,"./nl":14910,"./nl-be":72506,"./nl-be.js":72506,"./nl.js":14910,"./nn":12980,"./nn.js":12980,"./pa-in":33791,"./pa-in.js":33791,"./pl":1872,"./pl.js":1872,"./pt":9064,"./pt-br":85273,"./pt-br.js":85273,"./pt.js":9064,"./ro":63167,"./ro.js":63167,"./ru":28649,"./ru.js":28649,"./sd":14823,"./sd.js":14823,"./se":90672,"./se.js":90672,"./si":26244,"./si.js":26244,"./sk":40654,"./sk.js":40654,"./sl":44335,"./sl.js":44335,"./sq":79116,"./sq.js":79116,"./sr":60693,"./sr-cyrl":1436,"./sr-cyrl.js":1436,"./sr.js":60693,"./ss":51734,"./ss.js":51734,"./sv":37945,"./sv.js":37945,"./sw":41514,"./sw.js":41514,"./ta":1991,"./ta.js":1991,"./te":95011,"./te.js":95011,"./tet":19463,"./tet.js":19463,"./tg":43109,"./tg.js":43109,"./th":97144,"./th.js":97144,"./tl-ph":70401,"./tl-ph.js":70401,"./tlh":26678,"./tlh.js":26678,"./tr":28682,"./tr.js":28682,"./tzl":59084,"./tzl.js":59084,"./tzm":64307,"./tzm-latn":68869,"./tzm-latn.js":68869,"./tzm.js":64307,"./ug-cn":78812,"./ug-cn.js":78812,"./uk":25812,"./uk.js":25812,"./ur":25411,"./ur.js":25411,"./uz":59435,"./uz-latn":94589,"./uz-latn.js":94589,"./uz.js":59435,"./vi":50569,"./vi.js":50569,"./x-pseudo":85241,"./x-pseudo.js":85241,"./yo":96972,"./yo.js":96972,"./zh-cn":18422,"./zh-cn.js":18422,"./zh-hk":84106,"./zh-hk.js":84106,"./zh-tw":69362,"./zh-tw.js":69362}
4
3
  function s(e){var r=o(e)
5
4
  return t(r)}function o(e){if(!t.o(n,e)){var r=new Error("Cannot find module '"+e+"'")
6
- throw r.code="MODULE_NOT_FOUND",r}return n[e]}s.keys=function(){return Object.keys(n)},s.resolve=o,e.exports=s,s.id=56857},58660:(e,r,t)=>{e.exports=function(){_eai_d
5
+ throw r.code="MODULE_NOT_FOUND",r}return n[e]}s.keys=function(){return Object.keys(n)},s.resolve=o,e.exports=s,s.id=56857},57314:(e,r,t)=>{e.exports=function(){var e=_eai_d,r=_eai_r
6
+ function n(e){return e&&e.__esModule?e:Object.assign({default:e},e)}window.emberAutoImportDynamic=function(e){return 1===arguments.length?r("_eai_dyn_"+e):r("_eai_dynt_"+e)(Array.prototype.slice.call(arguments,1))},window.emberAutoImportSync=function(e){return r("_eai_sync_"+e)(Array.prototype.slice.call(arguments,1))},e("@sentry/browser",EAI_DISCOVERED_EXTERNALS("@sentry/browser"),function(){return n(t(32314))}),e("@sentry/core",EAI_DISCOVERED_EXTERNALS("@sentry/core"),function(){return n(t(67723))}),e("@sentry/integrations",EAI_DISCOVERED_EXTERNALS("@sentry/integrations"),function(){return n(t(20080))}),e("@sentry/replay",EAI_DISCOVERED_EXTERNALS("@sentry/replay"),function(){return n(t(51633))}),e("@sentry/utils",EAI_DISCOVERED_EXTERNALS("@sentry/utils"),function(){return n(t(5423))}),e("@tryghost/color-utils",EAI_DISCOVERED_EXTERNALS("@tryghost/color-utils"),function(){return n(t(86797))}),e("@tryghost/kg-clean-basic-html",EAI_DISCOVERED_EXTERNALS("@tryghost/kg-clean-basic-html"),function(){return n(t(3414))}),e("@tryghost/kg-converters",EAI_DISCOVERED_EXTERNALS("@tryghost/kg-converters"),function(){return n(t(23075))}),e("@tryghost/limit-service",EAI_DISCOVERED_EXTERNALS("@tryghost/limit-service"),function(){return n(t(55983))}),e("@tryghost/members-csv/lib/unparse",EAI_DISCOVERED_EXTERNALS("@tryghost/members-csv/lib/unparse"),function(){return n(t(17246))}),e("@tryghost/nql",EAI_DISCOVERED_EXTERNALS("@tryghost/nql"),function(){return n(t(39365))}),e("@tryghost/nql-lang",EAI_DISCOVERED_EXTERNALS("@tryghost/nql-lang"),function(){return n(t(716))}),e("@tryghost/string",EAI_DISCOVERED_EXTERNALS("@tryghost/string"),function(){return n(t(96107))}),e("@tryghost/timezone-data",EAI_DISCOVERED_EXTERNALS("@tryghost/timezone-data"),function(){return n(t(27019))}),e("animejs/lib/anime.es.js",EAI_DISCOVERED_EXTERNALS("animejs/lib/anime.es.js"),function(){return n(t(62282))}),e("element-resize-detector",EAI_DISCOVERED_EXTERNALS("element-resize-detector"),function(){return n(t(29540))}),e("ember-assign-helper/helpers/assign",EAI_DISCOVERED_EXTERNALS("ember-assign-helper/helpers/assign"),function(){return n(t(31113))}),e("ember-css-transitions/modifiers/css-transition",EAI_DISCOVERED_EXTERNALS("ember-css-transitions/modifiers/css-transition"),function(){return n(t(95895))}),e("ember-keyboard/helpers/if-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/helpers/if-key.js"),function(){return n(t(10530))}),e("ember-keyboard/helpers/on-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/helpers/on-key.js"),function(){return n(t(13692))}),e("ember-keyboard/modifiers/on-key.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/modifiers/on-key.js"),function(){return n(t(40985))}),e("ember-keyboard/services/keyboard.js",EAI_DISCOVERED_EXTERNALS("ember-keyboard/services/keyboard.js"),function(){return n(t(89697))}),e("ember-modifier",EAI_DISCOVERED_EXTERNALS("ember-modifier"),function(){return n(t(37777))}),e("ember-moment/helpers/-base",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/-base"),function(){return n(t(91366))}),e("ember-moment/helpers/is-after",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-after"),function(){return n(t(91461))}),e("ember-moment/helpers/is-before",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-before"),function(){return n(t(61e3))}),e("ember-moment/helpers/is-between",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-between"),function(){return n(t(447))}),e("ember-moment/helpers/is-same",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same"),function(){return n(t(64193))}),e("ember-moment/helpers/is-same-or-after",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same-or-after"),function(){return n(t(7916))}),e("ember-moment/helpers/is-same-or-before",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/is-same-or-before"),function(){return n(t(54351))}),e("ember-moment/helpers/moment",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment"),function(){return n(t(41678))}),e("ember-moment/helpers/moment-add",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-add"),function(){return n(t(50080))}),e("ember-moment/helpers/moment-calendar",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-calendar"),function(){return n(t(96625))}),e("ember-moment/helpers/moment-diff",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-diff"),function(){return n(t(85340))}),e("ember-moment/helpers/moment-duration",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-duration"),function(){return n(t(42967))}),e("ember-moment/helpers/moment-format",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-format"),function(){return n(t(10536))}),e("ember-moment/helpers/moment-from",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-from"),function(){return n(t(50727))}),e("ember-moment/helpers/moment-from-now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-from-now"),function(){return n(t(706))}),e("ember-moment/helpers/moment-subtract",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-subtract"),function(){return n(t(54651))}),e("ember-moment/helpers/moment-to",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to"),function(){return n(t(84818))}),e("ember-moment/helpers/moment-to-date",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to-date"),function(){return n(t(81183))}),e("ember-moment/helpers/moment-to-now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/moment-to-now"),function(){return n(t(17083))}),e("ember-moment/helpers/now",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/now"),function(){return n(t(34980))}),e("ember-moment/helpers/unix",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/unix"),function(){return n(t(79272))}),e("ember-moment/helpers/utc",EAI_DISCOVERED_EXTERNALS("ember-moment/helpers/utc"),function(){return n(t(36022))}),e("ember-moment/services/moment",EAI_DISCOVERED_EXTERNALS("ember-moment/services/moment"),function(){return n(t(39879))}),e("fast-deep-equal",EAI_DISCOVERED_EXTERNALS("fast-deep-equal"),function(){return n(t(25383))}),e("flexsearch",EAI_DISCOVERED_EXTERNALS("flexsearch"),function(){return n(t(12248))}),e("focus-trap",EAI_DISCOVERED_EXTERNALS("focus-trap"),function(){return n(t(39632))}),e("intersection-observer-admin",EAI_DISCOVERED_EXTERNALS("intersection-observer-admin"),function(){return n(t(21431))}),e("microdiff",EAI_DISCOVERED_EXTERNALS("microdiff"),function(){return n(t(59086))}),e("moment-timezone",EAI_DISCOVERED_EXTERNALS("moment-timezone"),function(){return n(t(41101))}),e("papaparse",EAI_DISCOVERED_EXTERNALS("papaparse"),function(){return n(t(78695))}),e("raf-pool",EAI_DISCOVERED_EXTERNALS("raf-pool"),function(){return n(t(60695))}),e("react",EAI_DISCOVERED_EXTERNALS("react"),function(){return n(t(72854))}),e("react-dom",EAI_DISCOVERED_EXTERNALS("react-dom"),function(){return n(t(95303))}),e("react-dom/client",EAI_DISCOVERED_EXTERNALS("react-dom/client"),function(){return n(t(70816))}),e("semver/functions/coerce",EAI_DISCOVERED_EXTERNALS("semver/functions/coerce"),function(){return n(t(18576))}),e("semver/functions/lt",EAI_DISCOVERED_EXTERNALS("semver/functions/lt"),function(){return n(t(32817))}),e("semver/functions/parse",EAI_DISCOVERED_EXTERNALS("semver/functions/parse"),function(){return n(t(47898))}),e("tooltip.js",EAI_DISCOVERED_EXTERNALS("tooltip.js"),function(){return n(t(85557))}),e("tracked-built-ins",EAI_DISCOVERED_EXTERNALS("tracked-built-ins"),function(){return n(t(67708))}),e("validator",EAI_DISCOVERED_EXTERNALS("validator"),function(){return n(t(29119))}),e("_eai_dyn_@sentry/browser",[],function(){return Promise.resolve().then(t.bind(t,32314))})}()},69383:function(e,r){window._eai_r=require,window._eai_d=define},77916:(e,r,t)=>{e.exports=function(){_eai_d
7
7
  var e=_eai_r
8
- window.emberAutoImportDynamic=function(r){return 1===arguments.length?e("_eai_dyn_"+r):e("_eai_dynt_"+r)(Array.prototype.slice.call(arguments,1))},window.emberAutoImportSync=function(r){return e("_eai_sync_"+r)(Array.prototype.slice.call(arguments,1))},t(36714)}()},80032:e=>{"use strict"
8
+ window.emberAutoImportDynamic=function(r){return 1===arguments.length?e("_eai_dyn_"+r):e("_eai_dynt_"+r)(Array.prototype.slice.call(arguments,1))},window.emberAutoImportSync=function(r){return e("_eai_sync_"+r)(Array.prototype.slice.call(arguments,1))},t(57314)}()},80032:e=>{"use strict"
9
9
  e.exports=require("ember-tracked-storage-polyfill")},86625:()=>{}},t={}
10
10
  function n(e){var s=t[e]
11
11
  if(void 0!==s)return s.exports
@@ -23,8 +23,8 @@ var r=(r,t)=>{var s,o,[m,E,i]=t,u=0
23
23
  if(m.some(r=>0!==e[r])){for(s in E)n.o(E,s)&&(n.m[s]=E[s])
24
24
  if(i)var a=i(n)}for(r&&r(t);u<m.length;u++)o=m[u],n.o(e,o)&&e[o]&&e[o][0](),e[o]=0
25
25
  return n.O(a)},t=globalThis.webpackChunk_ember_auto_import_=globalThis.webpackChunk_ember_auto_import_||[]
26
- t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),n.O(void 0,[397],()=>n(n.s=15263))
27
- var s=n.O(void 0,[397],()=>n(n.s=58660))
26
+ t.forEach(r.bind(null,0)),t.push=r.bind(null,t.push.bind(t))})(),n.O(void 0,[397],()=>n(n.s=69383))
27
+ var s=n.O(void 0,[397],()=>n(n.s=77916))
28
28
  s=n.O(s),__ember_auto_import__=s})()
29
29
 
30
- //# sourceMappingURL=chunk.582.343ddc9811a43f00de93.map
30
+ //# sourceMappingURL=chunk.582.0ed287001a73163b5634.map
@@ -6,7 +6,7 @@
6
6
  <title>Ghost</title>
7
7
 
8
8
 
9
- <meta name="ghost-admin/config/environment" content="%7B%22modulePrefix%22%3A%22ghost-admin%22%2C%22environment%22%3A%22production%22%2C%22cdnUrl%22%3A%22%22%2C%22editorUrl%22%3A%22%22%2C%22rootURL%22%3A%22%22%2C%22locationType%22%3A%22trailing-hash%22%2C%22EmberENV%22%3A%7B%22FEATURES%22%3A%7B%7D%2C%22EXTEND_PROTOTYPES%22%3A%7B%22Date%22%3Afalse%2C%22Array%22%3Atrue%2C%22String%22%3Atrue%2C%22Function%22%3Afalse%7D%2C%22_APPLICATION_TEMPLATE_WRAPPER%22%3Afalse%2C%22_JQUERY_INTEGRATION%22%3Atrue%2C%22_TEMPLATE_ONLY_GLIMMER_COMPONENTS%22%3Atrue%7D%2C%22APP%22%3A%7B%22version%22%3A%226.0%22%2C%22name%22%3A%22ghost-admin%22%7D%2C%22ember-simple-auth%22%3A%7B%7D%2C%22%40sentry%2Fember%22%3A%7B%22disablePerformance%22%3Atrue%2C%22sentry%22%3A%7B%7D%7D%2C%22ember-cli-mirage%22%3A%7B%22usingProxy%22%3Afalse%2C%22useDefaultPassthroughs%22%3Atrue%7D%2C%22exportApplicationGlobal%22%3Afalse%2C%22ember-load%22%3A%7B%22loadingIndicatorClass%22%3A%22ember-load-indicator%22%7D%2C%22editorFilename%22%3A%22koenig-lexical.umd.js%22%2C%22editorHash%22%3A%2237bd1e3e4d%22%2C%22adminXSettingsFilename%22%3A%22admin-x-settings.js%22%2C%22adminXSettingsHash%22%3A%2204c1ece7c0%22%2C%22adminXActivitypubFilename%22%3A%22admin-x-activitypub.js%22%2C%22adminXActivitypubHash%22%3A%225485f1b1fe%22%2C%22postsFilename%22%3A%22posts.js%22%2C%22postsHash%22%3A%2281ffce2b0e%22%2C%22statsFilename%22%3A%22stats.js%22%2C%22statsHash%22%3A%22d74e43efdd%22%2C%22adminXActivitypubCustomUrl%22%3A%22https%3A%2F%2Fcdn.jsdelivr.net%2Fghost%2Fadmin-x-activitypub%400%2Fdist%2Fadmin-x-activitypub.js%22%7D" />
9
+ <meta name="ghost-admin/config/environment" content="%7B%22modulePrefix%22%3A%22ghost-admin%22%2C%22environment%22%3A%22production%22%2C%22cdnUrl%22%3A%22%22%2C%22editorUrl%22%3A%22%22%2C%22rootURL%22%3A%22%22%2C%22locationType%22%3A%22trailing-hash%22%2C%22EmberENV%22%3A%7B%22FEATURES%22%3A%7B%7D%2C%22EXTEND_PROTOTYPES%22%3A%7B%22Date%22%3Afalse%2C%22Array%22%3Atrue%2C%22String%22%3Atrue%2C%22Function%22%3Afalse%7D%2C%22_APPLICATION_TEMPLATE_WRAPPER%22%3Afalse%2C%22_JQUERY_INTEGRATION%22%3Atrue%2C%22_TEMPLATE_ONLY_GLIMMER_COMPONENTS%22%3Atrue%7D%2C%22APP%22%3A%7B%22version%22%3A%226.0%22%2C%22name%22%3A%22ghost-admin%22%7D%2C%22ember-simple-auth%22%3A%7B%7D%2C%22%40sentry%2Fember%22%3A%7B%22disablePerformance%22%3Atrue%2C%22sentry%22%3A%7B%7D%7D%2C%22ember-cli-mirage%22%3A%7B%22usingProxy%22%3Afalse%2C%22useDefaultPassthroughs%22%3Atrue%7D%2C%22exportApplicationGlobal%22%3Afalse%2C%22ember-load%22%3A%7B%22loadingIndicatorClass%22%3A%22ember-load-indicator%22%7D%2C%22editorFilename%22%3A%22koenig-lexical.umd.js%22%2C%22editorHash%22%3A%2237bd1e3e4d%22%2C%22adminXSettingsFilename%22%3A%22admin-x-settings.js%22%2C%22adminXSettingsHash%22%3A%227a1707581a%22%2C%22adminXActivitypubFilename%22%3A%22admin-x-activitypub.js%22%2C%22adminXActivitypubHash%22%3A%22e7b144a148%22%2C%22postsFilename%22%3A%22posts.js%22%2C%22postsHash%22%3A%2281ffce2b0e%22%2C%22statsFilename%22%3A%22stats.js%22%2C%22statsHash%22%3A%22d74e43efdd%22%2C%22adminXActivitypubCustomUrl%22%3A%22https%3A%2F%2Fcdn.jsdelivr.net%2Fghost%2Fadmin-x-activitypub%400%2Fdist%2Fadmin-x-activitypub.js%22%7D" />
10
10
 
11
11
  <meta name="viewport" content="user-scalable=no, width=device-width, initial-scale=1, maximum-scale=1, minimal-ui, viewport-fit=cover" />
12
12
  <meta name="pinterest" content="nopin" />
@@ -49,7 +49,7 @@
49
49
 
50
50
  <script src="assets/vendor-aed0068cf9b67d042dd23a6343545b7b.js"></script>
51
51
  <script src="assets/chunk.397.f965bec6bb556d2750de.js"></script>
52
- <script src="assets/chunk.524.54926af287de331c1ed0.js"></script>
52
+ <script src="assets/chunk.524.9820d2bf73b62bb7dba9.js"></script>
53
53
  <script src="assets/ghost-dfaf1657ee466f4f397c27bbae0759bc.js"></script>
54
54
  </body>
55
55
  </html>
@@ -2,10 +2,10 @@ const express = require('../../../shared/express');
2
2
  const config = require('../../../shared/config');
3
3
  const urlUtils = require('../../../shared/url-utils');
4
4
 
5
- const adminRedirect = (path) => {
6
- return function doRedirect(req, res) {
7
- return urlUtils.redirectToAdmin(301, res, path);
8
- };
5
+ // Extract the core redirect logic for easier testing
6
+ const handleAdminRedirect = function (req, res) {
7
+ const adminPath = req.path.replace(/^\/ghost/, '') || '/';
8
+ return urlUtils.redirectToAdmin(301, res, adminPath);
9
9
  };
10
10
 
11
11
  // redirect to /ghost to the admin
@@ -13,8 +13,11 @@ module.exports = function redirectGhostToAdmin() {
13
13
  const router = express.Router('redirect-ghost-to-admin');
14
14
 
15
15
  if (config.get('admin:redirects')) {
16
- router.get(/^\/ghost\/?$/, adminRedirect('/'));
16
+ router.get(/^\/ghost(\/.*)?\/?$/, handleAdminRedirect);
17
17
  }
18
18
 
19
19
  return router;
20
20
  };
21
+
22
+ // Export the core logic for testing
23
+ module.exports.handleAdminRedirect = handleAdminRedirect;
@@ -19,6 +19,7 @@ const _addMemberContextToFrame = async (frame) => {
19
19
  // only set apiType when given a member_status to preserve backwards compatibility
20
20
  // where we used to serve "Admin API" content with no gating for all previews
21
21
  frame.apiType = 'content';
22
+ frame.isPreview = true;
22
23
 
23
24
  frame.original ??= {};
24
25
  frame.original.context ??= {};
@@ -40,5 +40,14 @@ module.exports = {
40
40
  */
41
41
  isInternal: (frame) => {
42
42
  return frame.options.context && frame.options.context.internal;
43
+ },
44
+
45
+ /**
46
+ * @description Returns true if the request is a preview request.
47
+ * @param {import('@tryghost/api-framework').Frame} frame
48
+ * @returns {boolean}
49
+ */
50
+ isPreview: (frame) => {
51
+ return frame.isPreview === true;
43
52
  }
44
53
  };
@@ -82,7 +82,9 @@ const post = (attrs, frame) => {
82
82
  const fields = frame && frame.original && frame.original.query && frame.original.query.fields || null;
83
83
 
84
84
  if (localUtils.isContentAPI(frame)) {
85
- delete attrs.status;
85
+ if (!localUtils.isPreview(frame)) {
86
+ delete attrs.status;
87
+ }
86
88
  delete attrs.email_only;
87
89
  delete attrs.newsletter;
88
90
  delete attrs.email_segment;
@@ -73,6 +73,19 @@ function createDropColumnMigration(table, column, columnDefinition) {
73
73
  function createSetNullableMigration(table, column, options = {}) {
74
74
  return createTransactionalMigration(
75
75
  async function up(knex) {
76
+ try {
77
+ // Check if column is already nullable
78
+ const isNullable = await isColumnNullable(table, column, knex);
79
+ if (isNullable) {
80
+ logging.warn(`Setting nullable: ${table}.${column} - skipping as column is already nullable`);
81
+ return;
82
+ }
83
+ } catch (error) {
84
+ // If we can't check the column status, proceed with the migration
85
+ // This maintains backward compatibility with implementation before checks were added
86
+ logging.warn(`Could not check nullable status for ${table}.${column}, proceeding with migration: ${error.message}`);
87
+ }
88
+
76
89
  logging.info(`Setting nullable: ${table}.${column}`);
77
90
  await commands.setNullable(table, column, knex);
78
91
  },
@@ -80,7 +93,21 @@ function createSetNullableMigration(table, column, options = {}) {
80
93
  if (DatabaseInfo.isSQLite(knex)) {
81
94
  options.disableForeignKeyChecks = false;
82
95
  }
83
- logging.info(`Dropping nullable: ${table}.${column}${options.disableForeignKeyChecks ? ' with foreign keys disabled' : ''}`);
96
+
97
+ try {
98
+ // Check if column is already not nullable
99
+ const isNotNullable = await isColumnNotNullable(table, column, knex);
100
+ if (isNotNullable) {
101
+ logging.warn(`Dropping nullable: ${table}.${column} - skipping as column is already not nullable`);
102
+ return;
103
+ }
104
+ } catch (error) {
105
+ // If we can't check the column status, proceed with the migration
106
+ // This maintains backward compatibility with implementation before checks were added
107
+ logging.warn(`Could not check nullable status for ${table}.${column}, proceeding with migration: ${error.message}`);
108
+ }
109
+
110
+ logging.info(`Dropping nullable: ${table}.${column}${options.disableForeignKeyChecks ? ' with foreign keys disabled' : ''}`);
84
111
  if (options.disableForeignKeyChecks) {
85
112
  await knex.raw('SET FOREIGN_KEY_CHECKS=0;').transacting(knex);
86
113
  }
@@ -140,6 +167,48 @@ function createRenameColumnMigration(table, from, to) {
140
167
  );
141
168
  }
142
169
 
170
+ /**
171
+ * Check if a column is already not nullable
172
+ * @param {string} table
173
+ * @param {string} column
174
+ * @param {import('knex').Knex} knex
175
+ * @returns {Promise<boolean>}
176
+ */
177
+ async function isColumnNotNullable(table, column, knex) {
178
+ const client = knex.client.config.client;
179
+
180
+ if (client === 'sqlite3') {
181
+ const response = await knex.raw('PRAGMA table_info(??)', [table]);
182
+ const columnInfo = response.find(col => col.name === column);
183
+ return columnInfo && columnInfo.notnull === 1;
184
+ } else {
185
+ const response = await knex.raw('SHOW COLUMNS FROM ??', [table]);
186
+ const columnInfo = response[0].find(col => col.Field === column);
187
+ return columnInfo && columnInfo.Null === 'NO';
188
+ }
189
+ }
190
+
191
+ /**
192
+ * Check if a column is already nullable
193
+ * @param {string} table
194
+ * @param {string} column
195
+ * @param {import('knex').Knex} knex
196
+ * @returns {Promise<boolean>}
197
+ */
198
+ async function isColumnNullable(table, column, knex) {
199
+ const client = knex.client.config.client;
200
+
201
+ if (client === 'sqlite3') {
202
+ const response = await knex.raw('PRAGMA table_info(??)', [table]);
203
+ const columnInfo = response.find(col => col.name === column);
204
+ return columnInfo && columnInfo.notnull === 0;
205
+ } else {
206
+ const response = await knex.raw('SHOW COLUMNS FROM ??', [table]);
207
+ const columnInfo = response[0].find(col => col.Field === column);
208
+ return columnInfo && columnInfo.Null === 'YES';
209
+ }
210
+ }
211
+
143
212
  /**
144
213
  * @param {string} table
145
214
  * @param {string} column
@@ -153,6 +222,20 @@ function createDropNullableMigration(table, column, options = {}) {
153
222
  if (DatabaseInfo.isSQLite(knex)) {
154
223
  options.disableForeignKeyChecks = false;
155
224
  }
225
+
226
+ try {
227
+ // Check if column is already not nullable
228
+ const isNotNullable = await isColumnNotNullable(table, column, knex);
229
+ if (isNotNullable) {
230
+ logging.warn(`Dropping nullable: ${table}.${column} - skipping as column is already not nullable`);
231
+ return;
232
+ }
233
+ } catch (error) {
234
+ // If we can't check the column status, proceed with the migration
235
+ // This maintains backward compatibility with implementation before checks were added
236
+ logging.warn(`Could not check nullable status for ${table}.${column}, proceeding with migration: ${error.message}`);
237
+ }
238
+
156
239
  logging.info(`Dropping nullable: ${table}.${column}${options.disableForeignKeyChecks ? ' with foreign keys disabled' : ''}`);
157
240
 
158
241
  if (options.disableForeignKeyChecks) {
@@ -168,6 +251,19 @@ function createDropNullableMigration(table, column, options = {}) {
168
251
  }
169
252
  },
170
253
  async function down(knex) {
254
+ try {
255
+ // Check if column is already nullable
256
+ const isNullable = await isColumnNullable(table, column, knex);
257
+ if (isNullable) {
258
+ logging.warn(`Setting nullable: ${table}.${column} - skipping as column is already nullable`);
259
+ return;
260
+ }
261
+ } catch (error) {
262
+ // If we can't check the column status, proceed with the migration
263
+ // This maintains backward compatibility with implementation before checks were added
264
+ logging.warn(`Could not check nullable status for ${table}.${column}, proceeding with migration: ${error.message}`);
265
+ }
266
+
171
267
  logging.info(`Setting nullable: ${table}.${column}`);
172
268
  await commands.setNullable(table, column, knex);
173
269
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ghost",
3
- "version": "6.0.1",
3
+ "version": "6.0.3",
4
4
  "description": "The professional publishing platform",
5
5
  "author": "Ghost Foundation",
6
6
  "homepage": "https://ghost.org",
@@ -86,7 +86,7 @@
86
86
  "@tryghost/helpers": "1.1.97",
87
87
  "@tryghost/html-to-plaintext": "1.0.4",
88
88
  "@tryghost/http-cache-utils": "0.1.20",
89
- "@tryghost/i18n": "file:components/tryghost-i18n-6.0.1.tgz",
89
+ "@tryghost/i18n": "file:components/tryghost-i18n-6.0.3.tgz",
90
90
  "@tryghost/image-transform": "1.4.6",
91
91
  "@tryghost/job-manager": "1.0.3",
92
92
  "@tryghost/kg-card-factory": "5.1.2",
@@ -232,7 +232,7 @@
232
232
  "@types/bookshelf": "1.2.9",
233
233
  "@types/common-tags": "1.8.4",
234
234
  "@types/jsonwebtoken": "9.0.10",
235
- "@types/node": "22.17.0",
235
+ "@types/node": "22.17.1",
236
236
  "@types/node-jose": "1.1.13",
237
237
  "@types/nodemailer": "6.4.17",
238
238
  "@types/sinon": "17.0.4",
@@ -247,7 +247,7 @@
247
247
  "form-data": "4.0.4",
248
248
  "html-minifier": "4.0.0",
249
249
  "html-validate": "8.29.0",
250
- "inquirer": "8.2.6",
250
+ "inquirer": "8.2.7",
251
251
  "jwk-to-pem": "2.0.7",
252
252
  "jwks-rsa": "3.2.0",
253
253
  "mocha": "11.7.1",
@@ -264,7 +264,7 @@
264
264
  "supertest": "6.3.4",
265
265
  "tmp": "0.2.3",
266
266
  "toml": "3.0.0",
267
- "tsx": "4.20.3",
267
+ "tsx": "4.20.4",
268
268
  "typescript": "5.8.3"
269
269
  },
270
270
  "resolutions": {
@@ -273,7 +273,7 @@
273
273
  "jackspeak": "2.3.6",
274
274
  "moment": "2.24.0",
275
275
  "moment-timezone": "0.5.45",
276
- "@tryghost/i18n": "file:components/tryghost-i18n-6.0.1.tgz"
276
+ "@tryghost/i18n": "file:components/tryghost-i18n-6.0.3.tgz"
277
277
  },
278
278
  "nx": {
279
279
  "targets": {