fix(server): prevent cross-library motion photo linking, made getByChecksum library specific (#8719)

prevent cross linking
This commit is contained in:
Kevin Huang
2024-04-11 06:41:30 -07:00
committed by GitHub
parent 37eea2d353
commit ec76e5ef23
4 changed files with 5 additions and 5 deletions

View File

@@ -405,7 +405,7 @@ export class MetadataService {
}
const checksum = this.cryptoRepository.hashSha1(video);
let motionAsset = await this.assetRepository.getByChecksum(asset.ownerId, checksum);
let motionAsset = await this.assetRepository.getByChecksum(asset.libraryId, checksum);
if (motionAsset) {
this.logger.debug(
`Asset ${asset.id}'s motion photo video with checksum ${checksum.toString(