diff --git a/wire/core/Inputfield.php b/wire/core/Inputfield.php index 7b2ef4bd..3650bb18 100644 --- a/wire/core/Inputfield.php +++ b/wire/core/Inputfield.php @@ -492,16 +492,6 @@ abstract class Inputfield extends WireData implements Module { * */ public function setParent(InputfieldWrapper $parent) { - if($this->parent && $this->parent instanceof InputfieldWrapper && $this->parent !== $parent) { - $oldRootParent = $this->getRootParent(); - if(!$oldRootParent) $oldRootParent = $this->parent; - $newRootParent = $parent->getRootParent(); - if(!$newRootParent) $newRootParent = $parent; - if($oldRootParent === $newRootParent) { - // if field staying in the same form, remove from previous parent - $this->parent->remove($this); - } - } $this->parent = $parent; return $this; }