fix javascrip toggle