changed named to processEvent