From a45e277f68713731db49942098118ebc68c33c72 Mon Sep 17 00:00:00 2001 From: Tomas Aparicio Date: Thu, 9 Jul 2015 23:31:51 +0100 Subject: [PATCH] refactor(resize) --- resize.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resize.go b/resize.go index 5769a0e..6e14960 100644 --- a/resize.go +++ b/resize.go @@ -45,7 +45,7 @@ func Resize(buf []byte, o Options) ([]byte, error) { // Do not enlarge the output if the input width or height // are already less than the required dimensions if o.Enlarge == false { - if inWidth < o.Width || inHeight < o.Height { + if inWidth < o.Width && inHeight < o.Height { factor = 1.0 shrink = 1 residual = 0