Adding JSHint. Adding missing and removing unnecessary variables.