jormungandr-bite/packages/backend/src/migration/1658939464003CustomMOTD.ts
2023-10-13 18:44:25 +02:00

11 lines
454 B
TypeScript

import { MigrationInterface, QueryRunner } from "typeorm";
export class CustomMOTD1658939464003 implements MigrationInterface {
async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "meta" ADD "customMOTD" character varying(256) array NOT NULL DEFAULT '{}'::varchar[]`,
);
}
async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE "meta" DROP COLUMN "customMOTD"`);
}
}