summary refs log tree commit diff
path: root/src/util/migration
diff options
context:
space:
mode:
authorCyberL1 <cyber.hf18@gmail.com>2025-11-08 15:21:39 +0100
committerCyberL1 <cyber.hf18@gmail.com>2025-11-08 15:21:39 +0100
commit2adee55ef8a9daa35bf63926f06c81c46e87f02a (patch)
tree11c038c955ee2584e48d729acd55f17701857646 /src/util/migration
parentMerge pull request #1372 from MathMan05/fixes (diff)
downloadserver-ts-2adee55ef8a9daa35bf63926f06c81c46e87f02a.tar.xz
fix: gif stickers should have `format_type` 4 instead of 0
Diffstat (limited to 'src/util/migration')
-rw-r--r--src/util/migration/postgres/1762611552514-fix-gif-stickers-format_type.ts11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/util/migration/postgres/1762611552514-fix-gif-stickers-format_type.ts b/src/util/migration/postgres/1762611552514-fix-gif-stickers-format_type.ts
new file mode 100644

index 00000000..47de7506 --- /dev/null +++ b/src/util/migration/postgres/1762611552514-fix-gif-stickers-format_type.ts
@@ -0,0 +1,11 @@ +import { MigrationInterface, QueryRunner } from "typeorm"; + +export class FixGifStickersFormatType1762611552514 implements MigrationInterface { + public async up(queryRunner: QueryRunner): Promise<void> { + await queryRunner.query(`UPDATE "stickers" SET "format_type" = 4 WHERE "format_type" = 0;`); + } + + public async down(queryRunner: QueryRunner): Promise<void> { + await queryRunner.query(`UPDATE "stickers" SET "format_type" = 0 WHERE "format_type" = 4;`); + } +}