Fixed already defined variable and unused variable. JSHint validated.