mirror of
https://github.com/immich-app/immich.git
synced 2025-01-01 08:31:59 +00:00
feat: Use video thumbnail for GIF types (#13677)
This commit is contained in:
parent
e98acc976e
commit
d40cbe4c5f
1 changed files with 3 additions and 3 deletions
|
@ -147,10 +147,10 @@ export class MediaService extends BaseService {
|
||||||
}
|
}
|
||||||
|
|
||||||
let generated: { previewPath: string; thumbnailPath: string; thumbhash: Buffer };
|
let generated: { previewPath: string; thumbnailPath: string; thumbhash: Buffer };
|
||||||
if (asset.type === AssetType.IMAGE) {
|
if (asset.type === AssetType.VIDEO || asset.originalFileName.toLowerCase().endsWith('.gif')) {
|
||||||
generated = await this.generateImageThumbnails(asset);
|
|
||||||
} else if (asset.type === AssetType.VIDEO) {
|
|
||||||
generated = await this.generateVideoThumbnails(asset);
|
generated = await this.generateVideoThumbnails(asset);
|
||||||
|
} else if (asset.type === AssetType.IMAGE) {
|
||||||
|
generated = await this.generateImageThumbnails(asset);
|
||||||
} else {
|
} else {
|
||||||
this.logger.warn(`Skipping thumbnail generation for asset ${id}: ${asset.type} is not an image or video`);
|
this.logger.warn(`Skipping thumbnail generation for asset ${id}: ${asset.type} is not an image or video`);
|
||||||
return JobStatus.SKIPPED;
|
return JobStatus.SKIPPED;
|
||||||
|
|
Loading…
Reference in a new issue