Fixed missing return in addToTemplate() method
Input::getAutoItem did not support additional parameters
Merge branch 'hotfix/4.2.2'