tidied up app.coffee