mirror of
https://github.com/immich-app/immich.git
synced 2025-05-24 01:12:58 -04:00
* skip stacked assets in duplicate detection * update sql * handle stacking after duplicate detection runs
15 lines
443 B
TypeScript
15 lines
443 B
TypeScript
import { MigrationInterface, QueryRunner } from 'typeorm';
|
|
|
|
export class UnsetStackedAssetsFromDuplicateStatus1740654480319 implements MigrationInterface {
|
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
await queryRunner.query(`
|
|
update assets
|
|
set "duplicateId" = null
|
|
where "stackId" is not null`);
|
|
}
|
|
|
|
public async down(): Promise<void> {
|
|
// No need to revert this migration
|
|
}
|
|
}
|