5.9. Firing a success event
To fire a success event at a request, the implementation must run these steps:
Let event be the result of creating an event using
[Event](https://www.w3.org/TR/dom41/#event)
.Set event’s
[type](https://www.w3.org/TR/dom41/#dom-event-type)
attribute to “success
“.Set event’s
[bubbles](https://www.w3.org/TR/dom41/#dom-event-bubbles)
and[cancelable](https://www.w3.org/TR/dom41/#dom-event-cancelable)
attributes to false.Let transaction be request’s transaction.
Let legacyOutputDidListenersThrowFlag be initially unset.
Set transaction’s active flag.
Dispatch event at request with legacyOutputDidListenersThrowFlag.
Unset transaction’s active flag.
If legacyOutputDidListenersThrowFlag is set, run the steps to abort a transaction with transaction and a newly created “
[AbortError](https://www.w3.org/TR/WebIDL-1/#aborterror)
“[DOMException](https://www.w3.org/TR/WebIDL-1/#idl-DOMException)
.