immich/server/src/migrations/1691600216749-UserMemoryPreference.ts
2024-03-20 21:02:51 +00:00

14 lines
507 B
TypeScript

import { MigrationInterface, QueryRunner } from 'typeorm';
export class UserMemoryPreference1691600216749 implements MigrationInterface {
name = 'UserMemoryPreference1691600216749';
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE "users" ADD "memoriesEnabled" boolean NOT NULL DEFAULT true`);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE "users" DROP COLUMN "memoriesEnabled"`);
}
}