diff --git a/wire/core/ImageSizerEngine.php b/wire/core/ImageSizerEngine.php index cf625c2b..80d1c253 100755 --- a/wire/core/ImageSizerEngine.php +++ b/wire/core/ImageSizerEngine.php @@ -1262,6 +1262,7 @@ abstract class ImageSizerEngine extends WireData implements Module, Configurable $options = array( 'quality' => $this->quality, 'webpQuality' => $this->webpQuality, + 'webpAdd' => $this->webpAdd, 'cropping' => $this->cropping, 'upscaling' => $this->upscaling, 'interlace' => $this->interlace, diff --git a/wire/core/ImageSizerEngineGD.php b/wire/core/ImageSizerEngineGD.php index 74f47d29..f58bb97c 100755 --- a/wire/core/ImageSizerEngineGD.php +++ b/wire/core/ImageSizerEngineGD.php @@ -413,8 +413,8 @@ class ImageSizerEngineGD extends ImageSizerEngine { */ protected function imSaveWebP($im, $filename, $quality = 90) { if(!function_exists('imagewebp')) return false; - $path_parts = pathinfo($filename); - $webpFilename = $path_parts['dirname'] . '/' . $path_parts['filename'] . '.webp'; + $path_parts = pathinfo($filename); + $webpFilename = $path_parts['dirname'] . '/' . $path_parts['filename'] . '.webp'; if(file_exists($webpFilename)) $this->wire('files')->unlink($webpFilename); return imagewebp($im, $webpFilename, $quality); }