refactor. MVC