Insert additional JS in the right place

This commit is contained in:
Dmitriy Simushev 2014-11-12 15:32:09 +00:00
parent c6d064a22e
commit 823cea36a7

View File

@ -83,7 +83,7 @@ class Plugin extends AbstractPlugin implements PluginInterface
$script->setAttribute('type', 'text/javascript');
$last_index = count($args['button']->getChildren()) - 1;
$args['button']->addChildAt($script, $last_index - 1);
$args['button']->addChildAt($script, $last_index);
}
}