diff options
Diffstat (limited to 'migration')
| -rw-r--r-- | migration/1565634203341-room.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/migration/1565634203341-room.ts b/migration/1565634203341-room.ts new file mode 100644 index 0000000000..783b375ff9 --- /dev/null +++ b/migration/1565634203341-room.ts @@ -0,0 +1,13 @@ +import {MigrationInterface, QueryRunner} from "typeorm"; + +export class room1565634203341 implements MigrationInterface { + + public async up(queryRunner: QueryRunner): Promise<any> { + await queryRunner.query(`ALTER TABLE "user_profile" ADD "room" jsonb NOT NULL DEFAULT '{}'`); + } + + public async down(queryRunner: QueryRunner): Promise<any> { + await queryRunner.query(`ALTER TABLE "user_profile" DROP COLUMN "room"`); + } + +} |