toggleClass: rename 'switch' variable

Closes gh-610
Fixes gh-581