factored controller out to its own file
removed comments