doc: close event is always emitted