mirror of
https://github.com/immich-app/immich.git
synced 2024-12-28 22:51: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 };
|
||||
if (asset.type === AssetType.IMAGE) {
|
||||
generated = await this.generateImageThumbnails(asset);
|
||||
} else if (asset.type === AssetType.VIDEO) {
|
||||
if (asset.type === AssetType.VIDEO || asset.originalFileName.toLowerCase().endsWith('.gif')) {
|
||||
generated = await this.generateVideoThumbnails(asset);
|
||||
} else if (asset.type === AssetType.IMAGE) {
|
||||
generated = await this.generateImageThumbnails(asset);
|
||||
} else {
|
||||
this.logger.warn(`Skipping thumbnail generation for asset ${id}: ${asset.type} is not an image or video`);
|
||||
return JobStatus.SKIPPED;
|
||||
|
|
Loading…
Reference in a new issue