mirror of
https://github.com/Unleash/unleash.git
synced 2024-12-28 00:06:53 +01:00
23 lines
406 B
JavaScript
23 lines
406 B
JavaScript
|
exports.up = function (db, cb) {
|
||
|
db.runSql(
|
||
|
`
|
||
|
ALTER TABLE environments ADD COLUMN protected BOOLEAN DEFAULT false;
|
||
|
UPDATE environments SET protected = true WHERE name = ':global:';
|
||
|
`,
|
||
|
cb,
|
||
|
);
|
||
|
};
|
||
|
|
||
|
exports.down = function (db, cb) {
|
||
|
db.runSql(
|
||
|
`
|
||
|
ALTER TABLE environments DROP COLUMN protected;
|
||
|
`,
|
||
|
cb,
|
||
|
);
|
||
|
};
|
||
|
|
||
|
exports._meta = {
|
||
|
version: 1,
|
||
|
};
|