bugfixing controller generator