Eliminate unused variables

I used jshint with '"unused": true' option.
Merge pull request #888 from tricknotes/eliminate-unused

Eliminate unused variables