Major code refactor --> MVC