Fix jshint errors

This unblocks @jongilbraith's #292 PR by resolving the jshint errors.

Could do with a lookover from the frontend guys @alexwllms @andrewtennison