1
0
mirror of https://github.com/immich-app/immich.git synced 2024-11-28 09:33:27 +02:00

fix: remove archived people from explore (#6091)

This commit is contained in:
martin 2024-01-01 17:07:42 +01:00 committed by GitHub
parent ca9cad20bc
commit 0ed89e61ec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -82,6 +82,7 @@ export class PersonRepository implements IPersonRepository {
.leftJoin('person.faces', 'face')
.where('person.ownerId = :userId', { userId })
.innerJoin('face.asset', 'asset')
.andWhere('asset.isArchived = false')
.orderBy('person.isHidden', 'ASC')
.addOrderBy("NULLIF(person.name, '') IS NULL", 'ASC')
.addOrderBy('COUNT(face.assetId)', 'DESC')

View File

@ -99,6 +99,7 @@ FROM
AND ("asset"."deletedAt" IS NULL)
WHERE
"person"."ownerId" = $1
AND "asset"."isArchived" = false
AND "person"."isHidden" = false
GROUP BY
"person"."id"