Skip to content

Commit 4350dce

Browse files
committed
Parse opacity only from color value array
fixes #100
1 parent 732faa9 commit 4350dce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Svg/Style.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ protected function fillStyles($styles)
169169
$value = $this->color;
170170
}
171171
}
172-
if ($value !== null && $value[3] !== 1 && array_key_exists("{$from}-opacity", $style_map) === true) {
172+
if (is_array($value) && $value[3] !== 1 && array_key_exists("{$from}-opacity", $style_map) === true) {
173173
$styles["{$from}-opacity"] = $value[3];
174174
}
175175
break;

0 commit comments

Comments
 (0)