Skip to content

Commit a75223d

Browse files
committed
Make ImageMagick Adapter compatible with php8 (Implicit conversion from float to int)
1 parent c766d6c commit a75223d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/internal/Magento/Framework/Image/Adapter/ImageMagick.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -212,14 +212,14 @@ public function resize($frameWidth = null, $frameHeight = null)
212212

213213
$newImage = new \Imagick();
214214
$newImage->newImage(
215-
$dims['frame']['width'],
216-
$dims['frame']['height'],
215+
floor($dims['frame']['width']),
216+
floor($dims['frame']['height']),
217217
$this->_imageHandler->getImageBackgroundColor()
218218
);
219219

220220
$this->_imageHandler->resizeImage(
221-
$dims['dst']['width'],
222-
$dims['dst']['height'],
221+
floor($dims['dst']['width']),
222+
floor($dims['dst']['height']),
223223
\Imagick::FILTER_CUBIC,
224224
self::BLUR_FACTOR
225225
);

0 commit comments

Comments
 (0)