js: fix double click from firing two events