Code readability improvements following Jslint