Slight refactor of app.coffee to make it clear what variables each logical group is using and to break functionality apart.