diff --git a/photos.js b/photos.js index f48ab07..6ed8f58 100644 --- a/photos.js +++ b/photos.js @@ -123,9 +123,9 @@ function uploadToCloud(storageConfig, targetPath, buffer) { } function getMetadata(src) { - return sharp(src).metadata() + return sharp(src, { failOnError: false }).metadata() } function makeResized(src, maxWidth, maxHeight) { - return sharp(src).rotate().resize({ height: maxHeight, width: maxWidth, fit: 'inside' }).toBuffer() + return sharp(src, { failOnError: false }).rotate().resize({ height: maxHeight, width: maxWidth, fit: 'inside' }).toBuffer() }