From 04dea8d788acfaf485f4aa9ad255e39f6aac2a08 Mon Sep 17 00:00:00 2001 From: TheArcaneBrony Date: Sat, 20 Aug 2022 03:27:03 +0200 Subject: prettier --- .../postgres/1660416055566-InvitersAreDeletable.ts | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'src/util/migrations/postgres/1660416055566-InvitersAreDeletable.ts') diff --git a/src/util/migrations/postgres/1660416055566-InvitersAreDeletable.ts b/src/util/migrations/postgres/1660416055566-InvitersAreDeletable.ts index e6101318..e8321ede 100644 --- a/src/util/migrations/postgres/1660416055566-InvitersAreDeletable.ts +++ b/src/util/migrations/postgres/1660416055566-InvitersAreDeletable.ts @@ -1,26 +1,25 @@ import { MigrationInterface, QueryRunner } from "typeorm"; export class InvitersAreDeletable1660416055566 implements MigrationInterface { - name = 'InvitersAreDeletable1660416055566' + name = "InvitersAreDeletable1660416055566"; - public async up(queryRunner: QueryRunner): Promise { - await queryRunner.query(` + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(` ALTER TABLE "invites" DROP CONSTRAINT "FK_15c35422032e0b22b4ada95f48f" `); - await queryRunner.query(` + await queryRunner.query(` ALTER TABLE "invites" ADD CONSTRAINT "FK_15c35422032e0b22b4ada95f48f" FOREIGN KEY ("inviter_id") REFERENCES "users"("id") ON DELETE CASCADE ON UPDATE NO ACTION `); - } + } - public async down(queryRunner: QueryRunner): Promise { - await queryRunner.query(` + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(` ALTER TABLE "invites" DROP CONSTRAINT "FK_15c35422032e0b22b4ada95f48f" `); - await queryRunner.query(` + await queryRunner.query(` ALTER TABLE "invites" ADD CONSTRAINT "FK_15c35422032e0b22b4ada95f48f" FOREIGN KEY ("inviter_id") REFERENCES "users"("id") ON DELETE NO ACTION ON UPDATE NO ACTION `); - } - + } } -- cgit 1.5.1