Made changes based off of jshint.