At last I will be able to remember that the type of an event is not a string, but a m2o to event.type model.