fix: fix PostgreSQL migrations and TelegramMessageThreadId migration (#1171)

* fix: fix PostgreSQL migrations and TelegramMessageThreadId migration

* fix: add missing migration to SQLite introduced by PostgreSQL
This commit is contained in:
Gauthier
2024-12-21 16:35:07 +01:00
committed by GitHub
parent d76d794411
commit 0491a04ef1
7 changed files with 593 additions and 425 deletions

View File

@@ -0,0 +1,19 @@
import type { MigrationInterface, QueryRunner } from 'typeorm';
export class AddTelegramMessageThreadId1734786596045
implements MigrationInterface
{
name = 'AddTelegramMessageThreadId1734786596045';
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "user_settings" ADD "telegramMessageThreadId" character varying`
);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "user_settings" DROP COLUMN "telegramMessageThreadId"`
);
}
}