import { MigrationInterface , QueryRunner } from "typeorm" ; export class ShadowBan1605799639880 implements MigrationInterface { name = 'ShadowBan1605799639880' ; public async up ( queryRunner ) { await queryRunner . query ( `ALTER TABLE "user" ADD "shadowBanned" boolean NOT NULL DEFAULT false` ) ; await queryRunner . query ( `COMMENT ON COLUMN "user"."codeImgIds" IS NULL` ) ; await queryRunner . query ( `ALTER TABLE "user" ALTER COLUMN "codeImgIds" SET DEFAULT '{}'::text[]` ) ; } public async down ( queryRunner ) { await queryRunner . query ( `ALTER TABLE "user" ALTER COLUMN "codeImgIds" SET DEFAULT '{}'` ) ; await queryRunner . query ( `COMMENT ON COLUMN "user"."codeImgIds" IS NULL` ) ; await queryRunner . query ( `ALTER TABLE "user" DROP COLUMN "shadowBanned"` ) ; } }