various fixes

This commit is contained in:
2021-12-13 13:48:20 +01:00
parent fdae6c106a
commit d01eaa8065
3 changed files with 241 additions and 232 deletions

View File

@@ -98,7 +98,7 @@ class SocialAction
{
if (!$this->children->contains($child)) {
$this->children[] = $child;
$child->setParent($this);
$child->setParent($this)->setIssue($this->getIssue());
}
return $this;
@@ -266,9 +266,16 @@ class SocialAction
{
$this->issue = $issue;
foreach ($this->getChildren() as $child) {
$child->setIssue($issue);
}
return $this;
}
/**
* @internal use $parent->addChild() instead (@see{self::addChild()})
*/
public function setParent(?self $parent): self
{
$this->parent = $parent;

View File

@@ -305,6 +305,9 @@ class SocialIssue
return $this;
}
/**
* @internal use @see{SocialIssue::addChild()} instead
*/
public function setParent(?self $parent): self
{
$this->parent = $parent;