diff --git a/app/src/main/java/protect/card_locker/Utils.java b/app/src/main/java/protect/card_locker/Utils.java index 787e73806..3ac53f674 100644 --- a/app/src/main/java/protect/card_locker/Utils.java +++ b/app/src/main/java/protect/card_locker/Utils.java @@ -594,6 +594,11 @@ public class Utils { double width = bitmap.getWidth(); double height = bitmap.getHeight(); + // Early exit + if (Math.max(width, height) <= maxSize) { + return bitmap; + } + if (height > width) { double scale = height / maxSize; height = maxSize;