From d6e927a8bee5eda0e33c3e3af68de0b22a45befa Mon Sep 17 00:00:00 2001 From: Ammar Githam Date: Sun, 27 Sep 2020 00:37:22 +0900 Subject: [PATCH] Fix wrong dimensions calculated due to last minute variable name change --- app/src/main/java/awais/instagrabber/utils/NumberUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/awais/instagrabber/utils/NumberUtils.java b/app/src/main/java/awais/instagrabber/utils/NumberUtils.java index f5f59c89..69db8011 100644 --- a/app/src/main/java/awais/instagrabber/utils/NumberUtils.java +++ b/app/src/main/java/awais/instagrabber/utils/NumberUtils.java @@ -59,7 +59,7 @@ public final class NumberUtils { public static Pair calculateWidthHeight(final int height, final int width, final int maxHeight, final int maxWidth) { int tempWidth = NumberUtils.getResultingWidth(maxHeight, height, width); int tempHeight = maxHeight; - if (width > maxWidth) { + if (tempWidth > maxWidth) { tempHeight = NumberUtils.getResultingHeight(maxWidth, height, width); tempWidth = maxWidth; }