update onClick method