removed debug stuff
fixed jslint warnings
fixed jslint warnings