Fix events processing