fix click handler bug