events bug fixed