Fixes example with events