Convert application.js.coffee to Javascript.
Fix syntax error.
Fix some JSHint complaints.