summary refs log tree commit diff
path: root/src/util/migration/postgres
diff options
context:
space:
mode:
authorTomatoCake <60300461+DEVTomatoCake@users.noreply.github.com>2024-08-13 21:43:19 +0200
committerTomatoCake <60300461+DEVTomatoCake@users.noreply.github.com>2024-08-13 21:43:19 +0200
commitdf794695ffd208f5607829ea64b2430f1ba56b00 (patch)
treef54141331e44dee911082491197ebfb2ad593e06 /src/util/migration/postgres
parentMerge pull request #1149 from DEVTomatoCake/feat/webhooks-3 (diff)
downloadserver-ts-df794695ffd208f5607829ea64b2430f1ba56b00.tar.xz
Icon for discovery categories & fix "primary_only"
Diffstat (limited to 'src/util/migration/postgres')
-rw-r--r--src/util/migration/postgres/1723577874393-discoveryCategoryIcon.ts13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/util/migration/postgres/1723577874393-discoveryCategoryIcon.ts b/src/util/migration/postgres/1723577874393-discoveryCategoryIcon.ts
new file mode 100644

index 000000000..29b4138a8 --- /dev/null +++ b/src/util/migration/postgres/1723577874393-discoveryCategoryIcon.ts
@@ -0,0 +1,13 @@ +import { MigrationInterface, QueryRunner } from "typeorm"; + +export class DiscoveryCategoryIcon1723577874393 implements MigrationInterface { + name = "DiscoveryCategoryIcon1723577874393"; + + public async up(queryRunner: QueryRunner): Promise<void> { + await queryRunner.query("ALTER TABLE categories ADD icon text NULL"); + } + + public async down(queryRunner: QueryRunner): Promise<void> { + await queryRunner.query("ALTER TABLE categories DROP COLUMN icon"); + } +}