Added support for custom controllers