event.http: fix end handling