Skip to content

Commit f0670b6

Browse files
Shikha MishraAmol Chaudhari
authored andcommitted
Updated Download.php
1 parent 994348f commit f0670b6

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

app/code/Magento/Downloadable/Helper/Download.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,9 @@ public function getContentType()
200200
return $this->_downloadableFile->getFileType($this->_resourceFile);
201201
}
202202
} elseif ($this->_linkType == self::LINK_TYPE_URL) {
203+
if(is_array($this->_handle->stat($this->_resourceFile)['type'])){
204+
return end($this->_handle->stat($this->_resourceFile)['type']);
205+
}else
203206
return $this->_handle->stat($this->_resourceFile)['type'];
204207
}
205208
return $this->_contentType;

0 commit comments

Comments
 (0)