Fixed bad MainController class