Refactoring controllers to separate code for each entity on its own file