clean up controller a bit

* add json content types
* weather readability
* trailing whitespace cleanup