Fixed more jslint warnings.
Removed unused code.