made tests pass jslint