Moved to MVC model