FoundKey/packages/backend/migration/1658146000392-remove-repo-url.js
Johann150 a0940c49a2
refactor: remove repositoryUrl & feedbackUrl from meta
These two URLs are static so there is no reason to keep them in the
database. They are also not even used anywhere by the API, so they can
also be removed from there.

Where they are used is in the nodeinfo, where they are now hardcoded.

While editing the nodeinfo, also uncommented nodeinfo version 2.1.
2022-07-18 14:39:27 +02:00

13 lines
606 B
JavaScript

export class removeRepoUrl1658146000392 {
name = 'removeRepoUrl1658146000392';
async up(queryRunner) {
await queryRunner.query(`ALTER TABLE "meta" DROP COLUMN "repositoryUrl"`);
await queryRunner.query(`ALTER TABLE "meta" DROP COLUMN "feedbackUrl"`);
}
async down(queryRunner) {
await queryRunner.query(`ALTER TABLE "meta" ADD "repositoryUrl" character varying(512) not null default 'https://github.com/misskey-dev/misskey'`);
await queryRunner.query(`ALTER TABLE "meta" ADD "feedbackUrl" character varying(512) default 'https://github.com/misskey-dev/misskey/issues/new'`);
}
}