Fixed bug with Controller class.

Was quite an issue, forgot to close a comment!