Minor fixes for #6 and jslint