diff --git a/server/src/immich/api-v1/asset/asset.service.ts b/server/src/immich/api-v1/asset/asset.service.ts index 6ce6c907b3..53335ceaf2 100644 --- a/server/src/immich/api-v1/asset/asset.service.ts +++ b/server/src/immich/api-v1/asset/asset.service.ts @@ -7,7 +7,6 @@ import { ICryptoRepository, IJobRepository, ImmichReadStream, - isSidecarFileType, isSupportedFileType, IStorageRepository, JobName, @@ -152,9 +151,8 @@ export class AssetService { } if (dto.sidecarPath) { - const sidecarType = mime.lookup(dto.sidecarPath) as string; - if (!isSidecarFileType(sidecarType)) { - throw new BadRequestException(`Unsupported sidecar file type ${assetPathType}`); + if (path.extname(dto.sidecarPath).toLowerCase() !== '.xmp') { + throw new BadRequestException(`Unsupported sidecar file type`); } }