Skip to content

Commit 0a4745b

Browse files
committed
fix(store): skip transform on unsupported image formats like .ico files
1 parent e694617 commit 0a4745b

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

packages/store/src/files-jobs.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,11 @@ export function jobFileTransformImage(s3Client) {
167167
return;
168168
}
169169

170-
if (file.contentLength === 0 || file.contentType === "image/svg+xml") {
170+
if (
171+
file.contentLength === 0 ||
172+
!STORE_FILE_IMAGE_TYPES.includes(file.contentType) ||
173+
file.contentType === "image/svg+xml"
174+
) {
171175
// Empty file is an empty transform, SVG's are not supported
172176
// @ts-expect-error
173177
await atomicSetTransformKey(sql, file.id, transformKey, file.id);

0 commit comments

Comments
 (0)