From 58a8e32778e1e64921c0c10f9456d767e60119b0 Mon Sep 17 00:00:00 2001 From: Jon Gilkison Date: Sun, 4 Nov 2018 05:14:07 +0700 Subject: [PATCH] Fix for a cropping bug --- classes/Tools/Imgix/ImgixTool.php | 2 +- ilab-media-tools.php | 2 +- readme.txt | 7 +++++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/classes/Tools/Imgix/ImgixTool.php b/classes/Tools/Imgix/ImgixTool.php index 12acc8bb..67aa9058 100644 --- a/classes/Tools/Imgix/ImgixTool.php +++ b/classes/Tools/Imgix/ImgixTool.php @@ -566,7 +566,7 @@ private function buildImgixImage($id, $size, $params = null, $skipParams = false } } - if(isset($sizeInfo['crop'])) { + if(isset($sizeInfo['crop']) && !empty($sizeInfo['crop'])) { $params['w'] = $sizeInfo['width'] ?: $sizeInfo['height']; $params['h'] = $sizeInfo['height'] ?: $sizeInfo['width']; $params['fit'] = 'crop'; diff --git a/ilab-media-tools.php b/ilab-media-tools.php index 019ea4ba..c572b5e1 100644 --- a/ilab-media-tools.php +++ b/ilab-media-tools.php @@ -4,7 +4,7 @@ Plugin URI: http://interfacelab.com/media-tools Description: Automatically upload media to Amazon S3 and integrate with Imgix, a real-time image processing CDN. Boosts site performance and simplifies workflows. Author: interfacelab -Version: 2.1.9 +Version: 2.1.11 Author URI: http://interfacelab.io */ diff --git a/readme.txt b/readme.txt index f664f9a1..246c79ef 100644 --- a/readme.txt +++ b/readme.txt @@ -6,7 +6,7 @@ Tested up to: 4.9.8 License: GPLv3 or later Donate link: http://www2.jdrf.org/site/TR?fr_id=6912&pg=personal&px=11429802 License URI: http://www.gnu.org/licenses/gpl-3.0.html -Stable tag: 2.1.8 +Stable tag: 2.1.11 Requires PHP: 5.6 Automatically upload media to Amazon S3 and integrate with Imgix, a real-time image processing CDN. Boosts site performance and simplifies workflows. @@ -105,7 +105,10 @@ We've tested a lot of media related plugins (sliders, image optimizers, media re == Changelog == -= 2.1.9 = += 2.1.11 = +* Fixed a cropping related bug + += 2.1.10 = * Using WordPress's image editor now works with Media Cloud. Crops, rotations, etc. will be re-uploaded to S3. * Added more Rekognition regions * When theme or plugin zip files are uploaded, skip handling them with Media Cloud