Commit 460b20ba authored by Thomas Citharel's avatar Thomas Citharel 🏃🏻
Browse files

Fix Undefined Fill property when adding a shape

parent e38d8acd
Pipeline #13269 passed with stage
in 14 minutes and 53 seconds
......@@ -13,13 +13,17 @@ class Shape extends Component
/** @var string */
private $markup;
public function __construct($component)
public function __construct(\stdClass $component)
{
parent::__construct($component);
$this->fill = $component->fill;
if (isset($component->fill)) {
$this->fill = $component->fill;
} else {
$this->fill = '#000000'; // default is black
}
$this->markup = $component->markup;
$this->markup = $component->markup;
}
/**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment