mirror of
https://github.com/immich-app/immich.git
synced 2025-12-24 01:11:32 +03:00
17 lines
746 B
TypeScript
17 lines
746 B
TypeScript
|
|
import { MigrationInterface, QueryRunner } from "typeorm";
|
||
|
|
|
||
|
|
export class AddAssetFaceIndicies1700752078178 implements MigrationInterface {
|
||
|
|
name = 'AddAssetFaceIndicies1700752078178'
|
||
|
|
|
||
|
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
||
|
|
await queryRunner.query(`CREATE INDEX "IDX_bf339a24070dac7e71304ec530" ON "asset_faces" ("personId", "assetId") `);
|
||
|
|
await queryRunner.query(`CREATE INDEX "IDX_b463c8edb01364bf2beba08ef1" ON "assets" ("stackParentId") `);
|
||
|
|
}
|
||
|
|
|
||
|
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
||
|
|
await queryRunner.query(`DROP INDEX "public"."IDX_b463c8edb01364bf2beba08ef1"`);
|
||
|
|
await queryRunner.query(`DROP INDEX "public"."IDX_bf339a24070dac7e71304ec530"`);
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|