mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Updated default value for image editor integration setting (#16897)
refs https://github.com/TryGhost/Team/issues/3145 Updates pintura integration to be switched on by default for all sites by adding a migration to update the default value for the setting.
This commit is contained in:
parent
c11c842b1e
commit
5c209abdc0
5 changed files with 30 additions and 11 deletions
|
@ -0,0 +1,19 @@
|
||||||
|
const logging = require('@tryghost/logging');
|
||||||
|
const {createTransactionalMigration} = require('../../utils');
|
||||||
|
|
||||||
|
module.exports = createTransactionalMigration(
|
||||||
|
async function up(knex) {
|
||||||
|
logging.info('Updating setting: "pintura" to "true"');
|
||||||
|
await knex('settings')
|
||||||
|
.where({
|
||||||
|
key: 'pintura'
|
||||||
|
})
|
||||||
|
.update({
|
||||||
|
value: 'true'
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
async function down() {
|
||||||
|
// no-op: this is a one way migration to set the default value for pintura integration
|
||||||
|
}
|
||||||
|
);
|
|
@ -530,7 +530,7 @@
|
||||||
},
|
},
|
||||||
"pintura": {
|
"pintura": {
|
||||||
"pintura": {
|
"pintura": {
|
||||||
"defaultValue": "false",
|
"defaultValue": "true",
|
||||||
"validations": {
|
"validations": {
|
||||||
"isIn": [
|
"isIn": [
|
||||||
[
|
[
|
||||||
|
|
|
@ -294,7 +294,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -684,7 +684,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -718,7 +718,7 @@ exports[`Settings API Edit Can edit a setting 2: [headers] 1`] = `
|
||||||
Object {
|
Object {
|
||||||
"access-control-allow-origin": "http://127.0.0.1:2369",
|
"access-control-allow-origin": "http://127.0.0.1:2369",
|
||||||
"cache-control": "no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0",
|
"cache-control": "no-cache, private, no-store, must-revalidate, max-stale=0, post-check=0, pre-check=0",
|
||||||
"content-length": "3993",
|
"content-length": "3992",
|
||||||
"content-type": "application/json; charset=utf-8",
|
"content-type": "application/json; charset=utf-8",
|
||||||
"content-version": StringMatching /v\\\\d\\+\\\\\\.\\\\d\\+/,
|
"content-version": StringMatching /v\\\\d\\+\\\\\\.\\\\d\\+/,
|
||||||
"etag": StringMatching /\\(\\?:W\\\\/\\)\\?"\\(\\?:\\[ !#-\\\\x7E\\\\x80-\\\\xFF\\]\\*\\|\\\\r\\\\n\\[\\\\t \\]\\|\\\\\\\\\\.\\)\\*"/,
|
"etag": StringMatching /\\(\\?:W\\\\/\\)\\?"\\(\\?:\\[ !#-\\\\x7E\\\\x80-\\\\xFF\\]\\*\\|\\\\r\\\\n\\[\\\\t \\]\\|\\\\\\\\\\.\\)\\*"/,
|
||||||
|
@ -1022,7 +1022,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -1359,7 +1359,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -1701,7 +1701,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -2131,7 +2131,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
@ -2533,7 +2533,7 @@ Object {
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura",
|
"key": "pintura",
|
||||||
"value": false,
|
"value": true,
|
||||||
},
|
},
|
||||||
Object {
|
Object {
|
||||||
"key": "pintura_js_url",
|
"key": "pintura_js_url",
|
||||||
|
|
|
@ -37,7 +37,7 @@ describe('DB version integrity', function () {
|
||||||
// Only these variables should need updating
|
// Only these variables should need updating
|
||||||
const currentSchemaHash = '2445c734ffb514d11b56e74591bcde4e';
|
const currentSchemaHash = '2445c734ffb514d11b56e74591bcde4e';
|
||||||
const currentFixturesHash = '869ceb3302303494c645f4201540ead3';
|
const currentFixturesHash = '869ceb3302303494c645f4201540ead3';
|
||||||
const currentSettingsHash = 'f9db81a9d2fe2fed5e9cfda1ccd2b3cc';
|
const currentSettingsHash = '4f23a583335dcb4cb3fae553122ea200';
|
||||||
const currentRoutesHash = '3d180d52c663d173a6be791ef411ed01';
|
const currentRoutesHash = '3d180d52c663d173a6be791ef411ed01';
|
||||||
|
|
||||||
// If this test is failing, then it is likely a change has been made that requires a DB version bump,
|
// If this test is failing, then it is likely a change has been made that requires a DB version bump,
|
||||||
|
|
|
@ -538,7 +538,7 @@
|
||||||
},
|
},
|
||||||
"pintura": {
|
"pintura": {
|
||||||
"pintura": {
|
"pintura": {
|
||||||
"defaultValue": "false",
|
"defaultValue": "true",
|
||||||
"validations": {
|
"validations": {
|
||||||
"isIn": [
|
"isIn": [
|
||||||
[
|
[
|
||||||
|
|
Loading…
Add table
Reference in a new issue