Removed jshint eqnull and fixed warnings