Skip to content

Commit

Permalink
Handle raw application/octet-stream content-type
Browse files Browse the repository at this point in the history
  • Loading branch information
Fondson authored Dec 29, 2024
1 parent 90b87eb commit 72cf0aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/downloadImagesInBatches.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ async function downloadImage(url: string, filename: string, folder: string) {
const hasMatchingExtension = regex.test(filename);

// Add appropriate extension to filename based on image format
const formattedFilename = hasMatchingExtension
const formattedFilename = hasMatchingExtension || imageFormat === 'octet-stream'
? filename
: `${filename}.${imageFormat}`;

Expand Down

0 comments on commit 72cf0aa

Please sign in to comment.