fixes event triggering issues