use strict in javascript. set validthis jshint option where applicable.