1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-12-22 15:24:46 -05:00

fix(extensiosn/web): AddEventListenerOptions.signal shouldn't be nullable (#11348)

This commit is contained in:
Divy Srivastava 2021-07-10 19:43:58 +05:30 committed by GitHub
parent 5bf753713c
commit b3f22d3fdd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View file

@ -929,7 +929,10 @@
this.removeEventListener(type, callback, options);
});
}
} else if (options?.signal === null) {
throw new TypeError("signal must be non-null");
}
ArrayPrototypePush(listeners[type], { callback, options });
}

View file

@ -1977,9 +1977,7 @@
"event.any.html": true
},
"events": {
"AddEventListenerOptions-signal.any.html": [
"Passing null as the signal should throw"
],
"AddEventListenerOptions-signal.any.html": true,
"Event-isTrusted.any.html": true,
"EventTarget-constructible.any.html": true,
"Event-constructors.any.html": [