From a6c0882d985cec89f7242354e3234c1ecd00aafe Mon Sep 17 00:00:00 2001 From: Charly Poirier Date: Tue, 21 Feb 2023 18:28:51 +0100 Subject: [PATCH] Fix resizing issue with Jimp.AUTO (#880) (#1202) --- packages/plugin-resize/src/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/plugin-resize/src/index.js b/packages/plugin-resize/src/index.js index 2c77df99a..5b269d54a 100644 --- a/packages/plugin-resize/src/index.js +++ b/packages/plugin-resize/src/index.js @@ -48,8 +48,8 @@ export default () => ({ } // round inputs - w = Math.round(w); - h = Math.round(h); + w = Math.round(w) || 1; + h = Math.round(h) || 1; if (typeof Resize2[mode] === "function") { const dst = {