changes to be jslint compliant