summaryrefslogtreecommitdiff
path: root/lib/exe
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2014-01-19 11:16:06 -0800
committerAndreas Gohr <andi@splitbrain.org>2014-01-19 11:16:06 -0800
commit93c7482b06953931f70d639cec328e9c0d6613bc (patch)
tree1e7bab382512678c63378b77fb560cac5f96a4f7 /lib/exe
parent0f569f4da813eb51aa75b3fe4a6e5c871b688eea (diff)
parente175e163722d806ebf45aa1e9a7843c2391a5b20 (diff)
downloadrpg-93c7482b06953931f70d639cec328e9c0d6613bc.tar.gz
rpg-93c7482b06953931f70d639cec328e9c0d6613bc.tar.bz2
Merge pull request #454 from lisps/resize_image-height
Resize image by height
Diffstat (limited to 'lib/exe')
-rw-r--r--lib/exe/fetch.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/exe/fetch.php b/lib/exe/fetch.php
index 5967494bf..f33b3f2f8 100644
--- a/lib/exe/fetch.php
+++ b/lib/exe/fetch.php
@@ -78,8 +78,8 @@ if (defined('SIMPLE_TEST')) {
unset($evt);
//handle image resizing/cropping
- if((substr($MIME, 0, 5) == 'image') && $WIDTH) {
- if($HEIGHT) {
+ if((substr($MIME, 0, 5) == 'image') && ($WIDTH || $HEIGHT)) {
+ if($HEIGHT && $WDITH) {
$data['file'] = $FILE = media_crop_image($data['file'], $EXT, $WIDTH, $HEIGHT);
} else {
$data['file'] = $FILE = media_resize_image($data['file'], $EXT, $WIDTH, $HEIGHT);