Check if the event name is valid