From b8b461f0dba77eb0714fa8af3d33c92e376fdc0f Mon Sep 17 00:00:00 2001 From: CyberL1 Date: Sun, 13 Jul 2025 07:30:17 +0200 Subject: fix: getting message pinss --- .../postgres/1752383879533-message_pinned_at.ts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/util/migration/postgres/1752383879533-message_pinned_at.ts (limited to 'src/util/migration/postgres') diff --git a/src/util/migration/postgres/1752383879533-message_pinned_at.ts b/src/util/migration/postgres/1752383879533-message_pinned_at.ts new file mode 100644 index 000000000..f96d284c1 --- /dev/null +++ b/src/util/migration/postgres/1752383879533-message_pinned_at.ts @@ -0,0 +1,17 @@ +import { MigrationInterface, QueryRunner } from "typeorm"; + +export class MessagePinnedAt1752383879533 implements MigrationInterface { + name = "MessagePinnedAt1752383879533"; + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `ALTER TABLE "messages" ADD "pinned_at" TIMESTAMP`, + ); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `ALTER TABLE "messages" DROP COLUMN "pinned_at"`, + ); + } +} -- cgit 1.5.1