Skip to content

Commit

Permalink
Added error handling for unhandled catch
Browse files Browse the repository at this point in the history
  • Loading branch information
temporary-simon committed Jul 24, 2023
1 parent 2255317 commit a278e4e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/imageProcessor.js
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ export async function getImagesFromClipboardItems(items, folder_id) {
const image = createImageDTO(folder_id, blob, data);
return image;
});
return await Promise.all(imagePromises);
return await Promise.all(imagePromises).catch((err) => {
console.error("Error occured contact @simonsejse on GitHub: ", err);
return [];
});
}

/**
Expand Down

0 comments on commit a278e4e

Please sign in to comment.