Extend 'emit' to lookup the event-name for objects with a '@type' field