Skip to content

Commit b900007

Browse files
author
flavien.chantelot
committed
Fix for issue magento#716. Wrong mimetype returned by magento image library
1 parent 796e984 commit b900007

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

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

+3-3
Original file line numberDiff line numberDiff line change
@@ -291,12 +291,12 @@ public function __construct(\Magento\Framework\Filesystem $filesystem, array $da
291291
* Assign image width, height, fileType and fileMimeType to object properties
292292
* using getimagesize function
293293
*
294-
* @return int|null
294+
* @return string
295295
*/
296296
public function getMimeType()
297297
{
298-
if ($this->_fileType) {
299-
return $this->_fileType;
298+
if ($this->_fileMimeType) {
299+
return $this->_fileMimeType;
300300
} else {
301301
list($this->_imageSrcWidth, $this->_imageSrcHeight, $this->_fileType, ) = getimagesize($this->_fileName);
302302
$this->_fileMimeType = image_type_to_mime_type($this->_fileType);

0 commit comments

Comments
 (0)