MainController finished, not tested