Fixed JSHint issues with code code will now produce no warnings in jshint.