Skip to content

Commit

Permalink
ENGCOM-2786: Typo in Magento\Cms\Model\Wysiwyg\Images\Storage functio…
Browse files Browse the repository at this point in the history
…n resizeFile() #17596

 - Merge Pull Request #17596 from eduard13/magento2:2.3-develop-17587-issue
 - Merged commits:
   1. 9a5bfd3
  • Loading branch information
magento-engcom-team committed Aug 14, 2018
2 parents 05f9df7 + 9a5bfd3 commit 0ea1ba3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/code/Magento/Cms/Model/Wysiwyg/Images/Storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -567,10 +567,10 @@ public function getThumbnailUrl($filePath, $checkFile = false)
* Create thumbnail for image and save it to thumbnails directory
*
* @param string $source Image path to be resized
* @param bool $keepRation Keep aspect ratio or not
* @param bool $keepRatio Keep aspect ratio or not
* @return bool|string Resized filepath or false if errors were occurred
*/
public function resizeFile($source, $keepRation = true)
public function resizeFile($source, $keepRatio = true)
{
$realPath = $this->_directory->getRelativePath($source);
if (!$this->_directory->isFile($realPath) || !$this->_directory->isExist($realPath)) {
Expand All @@ -587,7 +587,7 @@ public function resizeFile($source, $keepRation = true)
}
$image = $this->_imageFactory->create();
$image->open($source);
$image->keepAspectRatio($keepRation);
$image->keepAspectRatio($keepRatio);
$image->resize($this->_resizeParameters['width'], $this->_resizeParameters['height']);
$dest = $targetDir . '/' . pathinfo($source, PATHINFO_BASENAME);
$image->save($dest);
Expand Down

0 comments on commit 0ea1ba3

Please sign in to comment.