corrected click event