From d52a56e1b845c0c3835ff216f1d54a636e33bba9 Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Fri, 16 May 2008 15:13:48 +0200 Subject: always crop when height is given darcs-hash:20080516131348-7ad00-499fcf8660323913e0cff1fbf85d9ffb56ea113b.gz --- lib/exe/fetch.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'lib/exe/fetch.php') diff --git a/lib/exe/fetch.php b/lib/exe/fetch.php index d0caffd46..cdcc4dd21 100644 --- a/lib/exe/fetch.php +++ b/lib/exe/fetch.php @@ -24,7 +24,6 @@ $CACHE = calc_cache($_REQUEST['cache']); $WIDTH = (int) $_REQUEST['w']; $HEIGHT = (int) $_REQUEST['h']; - $CROP = (bool) $_REQUEST['crop']; list($EXT,$MIME) = mimetype($MEDIA); if($EXT === false){ $EXT = 'unknown'; @@ -68,7 +67,7 @@ //handle image resizing/cropping if((substr($MIME,0,5) == 'image') && $WIDTH){ - if($CROP){ + if($HEIGHT){ $FILE = get_cropped($FILE,$EXT,$WIDTH,$HEIGHT); }else{ $FILE = get_resized($FILE,$EXT,$WIDTH,$HEIGHT); -- cgit v1.2.3