Skip to content

Commit

Permalink
Fixed exception when removing container
Browse files Browse the repository at this point in the history
Nette\InvalidStateException: Component 'remove' is not attached to 'Nette\Forms\Form'.
  • Loading branch information
fprochazka committed Jan 17, 2014
1 parent b64040a commit 2aa65fe
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Kdyby/Replicator/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,9 @@ public static function register($methodName = 'addDynamic')
if (is_callable($callback)) {
callback($callback)->invoke($replicator, $button->parent);
}
if ($form = $button->getForm(FALSE)) {
$form->onSuccess = array();
}
$replicator->remove($button->parent);
};
return $_this;
Expand Down

0 comments on commit 2aa65fe

Please sign in to comment.