This commit is contained in:
Steffen Schröder
2014-01-12 14:47:17 +01:00
parent ca12a1e6fd
commit 8593f10ecc
3 changed files with 5 additions and 3 deletions

View File

@ -95,7 +95,9 @@ class ManiaLink implements Container {
* @return \FML\ManiaLink
*/
public function add(Renderable $child) {
array_push($this->children, $child);
if (!in_array($child, $this->children, true)) {
array_push($this->children, $child);
}
return $this;
}