move controller class to its own file