Fixed toggle selector

Changed .click call to properly pass data to selected variable, tweaked
output code