Refactor AnnotationEventSink and fix a typo