Skip to content

Commit d6b4f23

Browse files
authored
BUGFIX #820 createDrawingShape stopped working in 1.1.0
Added setContainer in ShapeCollection::addShape().
1 parent 04700ed commit d6b4f23

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/PhpPresentation/Traits/ShapeCollection.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@ public function addShape(AbstractShape $shape)
8181
{
8282
$this->shapeCollection[] = $shape;
8383

84+
if (method_exists($shape, 'setContainer') && $shape->getContainer() === null) {
85+
$shape->setContainer($this);
86+
}
87+
8488
return $this;
8589
}
8690

0 commit comments

Comments
 (0)