mirror of
https://github.com/immich-app/immich
synced 2025-11-07 17:27:20 +00:00
feat(server): link via profile.sub (#1055)
This commit is contained in:
parent
424b11cf50
commit
99854e90be
9 changed files with 64 additions and 3 deletions
|
|
@ -23,6 +23,9 @@ export class UserEntity {
|
|||
@Column({ default: '', select: false })
|
||||
salt?: string;
|
||||
|
||||
@Column({ default: '', select: false })
|
||||
oauthId!: string;
|
||||
|
||||
@Column({ default: '' })
|
||||
profileImagePath!: string;
|
||||
|
||||
|
|
|
|||
14
server/libs/database/src/migrations/1670104716264-OAuthId.ts
Normal file
14
server/libs/database/src/migrations/1670104716264-OAuthId.ts
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class OAuthId1670104716264 implements MigrationInterface {
|
||||
name = 'OAuthId1670104716264'
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE "users" ADD "oauthId" character varying NOT NULL DEFAULT ''`);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE "users" DROP COLUMN "oauthId"`);
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue