Remove unused code, superflous todos, and clean up jshint errors.