Merge branch 'dev'
commit
1647fdb215
|
@ -1,7 +1,10 @@
|
||||||
/.vscode
|
/.vscode
|
||||||
/.idea
|
/.idea
|
||||||
/node_modules
|
/node_modules
|
||||||
/config.*
|
|
||||||
!/config.example.ini
|
|
||||||
/welcome.png
|
/welcome.png
|
||||||
/update.sh
|
/update.sh
|
||||||
|
|
||||||
|
# Config files
|
||||||
|
/config.*
|
||||||
|
*.config.ini
|
||||||
|
!/config.example.ini
|
||||||
|
|
|
@ -1396,10 +1396,10 @@
|
||||||
"integrity": "sha512-6u0VYSCo/OW6IoD5WCLLy9JUGARbamfSavcNXry/eu8aHVFei6CD3Sw+VGX5alea1i9pgPHW0mbu6Xj0uBh7gA=="
|
"integrity": "sha512-6u0VYSCo/OW6IoD5WCLLy9JUGARbamfSavcNXry/eu8aHVFei6CD3Sw+VGX5alea1i9pgPHW0mbu6Xj0uBh7gA=="
|
||||||
},
|
},
|
||||||
"eris": {
|
"eris": {
|
||||||
"version": "https://github.com/Dragory/eris/archive/stickers-0.14.0.tar.gz",
|
"version": "https://github.com/Dragory/eris/archive/0.14.0-stage-hotfix.tar.gz",
|
||||||
"integrity": "sha512-4L04+OUPdKaADpFyatM0FYpNRYRCJSdYEIFRpVbPGjQUeHO4XkbqNZ4knL5yedMJqzzib3u2qFIJUkHu9HgAbw==",
|
"integrity": "sha512-zKnRLTkzi2d8Twrf1I8fNAePVeN3pCGgtXvZ+66eVlFsS6CIkppm0IzHG+tn9pMGf1PpFwzgxMdV1hiPUVyGSQ==",
|
||||||
"requires": {
|
"requires": {
|
||||||
"opusscript": "^0.0.7",
|
"opusscript": "^0.0.8",
|
||||||
"tweetnacl": "^1.0.1",
|
"tweetnacl": "^1.0.1",
|
||||||
"ws": "^7.2.1"
|
"ws": "^7.2.1"
|
||||||
}
|
}
|
||||||
|
@ -3896,9 +3896,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"opusscript": {
|
"opusscript": {
|
||||||
"version": "0.0.7",
|
"version": "0.0.8",
|
||||||
"resolved": "https://registry.npmjs.org/opusscript/-/opusscript-0.0.7.tgz",
|
"resolved": "https://registry.npmjs.org/opusscript/-/opusscript-0.0.8.tgz",
|
||||||
"integrity": "sha512-DcBadTdYTUuH9zQtepsLjQn4Ll6rs3dmeFvN+SD0ThPnxRBRm/WC1zXWPg+wgAJimB784gdZvUMA57gDP7FdVg==",
|
"integrity": "sha512-VSTi1aWFuCkRCVq+tx/BQ5q9fMnQ9pVZ3JU4UHKqTkf0ED3fKEPdr+gKAAl3IA2hj9rrP6iyq3hlcJq3HELtNQ==",
|
||||||
"optional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"os-homedir": {
|
"os-homedir": {
|
||||||
|
@ -5580,9 +5580,9 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ws": {
|
"ws": {
|
||||||
"version": "7.3.1",
|
"version": "7.4.4",
|
||||||
"resolved": "https://registry.npmjs.org/ws/-/ws-7.3.1.tgz",
|
"resolved": "https://registry.npmjs.org/ws/-/ws-7.4.4.tgz",
|
||||||
"integrity": "sha512-D3RuNkynyHmEJIpD2qrgVkc9DQ23OrN/moAwZX4L8DfvszsJxpjQuUq3LMx6HoYji9fbIOBY18XWBsAux1ZZUA=="
|
"integrity": "sha512-Qm8k8ojNQIMx7S+Zp8u/uHOx7Qazv3Yv4q68MiWWWOJhiwG5W3x7iqmRtJo8xxrciZUY4vRxUTJCKuRnF28ZZw=="
|
||||||
},
|
},
|
||||||
"xmlcreate": {
|
"xmlcreate": {
|
||||||
"version": "2.0.3",
|
"version": "2.0.3",
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"ajv": "^6.12.4",
|
"ajv": "^6.12.4",
|
||||||
"eris": "https://github.com/Dragory/eris/archive/stickers-0.14.0.tar.gz",
|
"eris": "https://github.com/Dragory/eris/archive/0.14.0-stage-hotfix.tar.gz",
|
||||||
"express": "^4.17.1",
|
"express": "^4.17.1",
|
||||||
"helmet": "^4.1.1",
|
"helmet": "^4.1.1",
|
||||||
"humanize-duration": "^3.23.1",
|
"humanize-duration": "^3.23.1",
|
||||||
|
|
|
@ -0,0 +1,41 @@
|
||||||
|
exports.up = async function(knex) {
|
||||||
|
await knex.schema.renameTable("moderator_role_overrides", "old_moderator_role_overrides");
|
||||||
|
|
||||||
|
await knex.schema.createTable("moderator_role_overrides", table => {
|
||||||
|
table.increments("id");
|
||||||
|
table.string("moderator_id", 20).notNullable();
|
||||||
|
table.string("thread_id", 36).nullable().defaultTo(null);
|
||||||
|
table.string("role_id", 20).notNullable();
|
||||||
|
|
||||||
|
table.unique(["moderator_id", "thread_id"]);
|
||||||
|
});
|
||||||
|
|
||||||
|
const rows = await knex.table("old_moderator_role_overrides")
|
||||||
|
.select();
|
||||||
|
|
||||||
|
await knex.table("moderator_role_overrides").insert(rows);
|
||||||
|
|
||||||
|
await knex.schema.dropTable("old_moderator_role_overrides");
|
||||||
|
};
|
||||||
|
|
||||||
|
exports.down = async function(knex) {
|
||||||
|
await knex.schema.renameTable("moderator_role_overrides", "new_moderator_role_overrides");
|
||||||
|
|
||||||
|
await knex.schema.createTable("moderator_role_overrides", table => {
|
||||||
|
table.string("moderator_id", 20);
|
||||||
|
table.string("thread_id", 36).nullable().defaultTo(null);
|
||||||
|
table.string("role_id", 20);
|
||||||
|
|
||||||
|
table.primary(["moderator_id", "thread_id"]);
|
||||||
|
});
|
||||||
|
|
||||||
|
const rows = await knex.table("new_moderator_role_overrides")
|
||||||
|
.select();
|
||||||
|
|
||||||
|
await knex.table("moderator_role_overrides").insert(rows.map(r => {
|
||||||
|
delete r.id;
|
||||||
|
return r;
|
||||||
|
}));
|
||||||
|
|
||||||
|
await knex.schema.dropTable("new_moderator_role_overrides");
|
||||||
|
};
|
Loading…
Reference in New Issue