fix(server): person thumbnail generation always being queued (#15734)

* fix person thumbnail generation always being queued

* fix thumbhash comparison

* fix mock
This commit is contained in:
Mert
2025-01-27 17:20:18 -05:00
committed by GitHub
parent 64d926581f
commit 92412ca2f7
4 changed files with 3 additions and 5 deletions

View File

@@ -194,7 +194,7 @@ export class MediaService extends BaseService {
await Promise.all(pathsToDelete.map((path) => this.storageRepository.unlink(path)));
}
if (asset.thumbhash != generated.thumbhash) {
if (!asset.thumbhash || Buffer.compare(asset.thumbhash, generated.thumbhash) !== 0) {
await this.assetRepository.update({ id: asset.id, thumbhash: generated.thumbhash });
}