refactoring of conditions in fireEvent