Skip to content

High performance self-hosted photo and video management solution.

fix(server): link live photos (#15612)

Alexec7ab209f3a9
diff --git a/server/src/repositories/asset.repository.ts b/server/src/repositories/asset.repository.ts
index 9c506197d6..6bb253d183 100644
--- a/server/src/repositories/asset.repository.ts
+++ b/server/src/repositories/asset.repository.ts
@@ -430,9 +430,9 @@ export class AssetRepository implements IAssetRepository {
findLivePhotoMatch(options: LivePhotoSearchOptions): Promise<AssetEntity | undefined> {
const { ownerId, otherAssetId, livePhotoCID, type } = options;
-
return this.db
.selectFrom('assets')
+ .select('assets.id')
.innerJoin('exif', 'assets.id', 'exif.assetId')
.where('id', '!=', asUuid(otherAssetId))
.where('ownerId', '=', asUuid(ownerId))