Fix JSLint/JSHint complains

Used settings:

JSList: /*jslint nomen: true, regexp: true, todo: true, vars: true,
white: true, browser: true, devel: true */

JSHit: /*jshint eqnull:true, noarg:true, noempty:true, boss:true,
bitwise:true, undef:true, curly:true, browser:true, devel:true,
jquery:true, indent:4, maxerr:50 */