Skip to content

Commit d85d5ea

Browse files
authored
Merge pull request #41 from experius/feature/DOBO-786
Feature/dobo 786
2 parents 6771518 + a35b7c1 commit d85d5ea

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Image/Adapter/Gd2.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ public function __construct(
4545
public function open($filename)
4646
{
4747
$pathInfo = pathinfo($filename);
48-
if (!key_exists('extension', $pathInfo)
49-
|| !in_array($pathInfo['extension'], $this->settings->getExtraFiletypes())
48+
if (key_exists('extension', $pathInfo)
49+
&& in_array($pathInfo['extension'], $this->settings->getExtraFiletypes())
5050
) {
5151
parent::open($filename);
5252
}
@@ -65,8 +65,8 @@ public function save($destination = null, $newName = null)
6565
{
6666
$fileName = $this->_prepareDestination($destination, $newName);
6767
$pathInfo = pathinfo($fileName);
68-
if (!key_exists('extension', $pathInfo)
69-
|| !in_array($pathInfo['extension'], $this->settings->getExtraFiletypes())
68+
if (key_exists('extension', $pathInfo)
69+
&& in_array($pathInfo['extension'], $this->settings->getExtraFiletypes())
7070
) {
7171
parent::save($destination, $newName);
7272
}

0 commit comments

Comments
 (0)