lib: use full URL to GitHub issues in comments

Don't assume the reader of the code will know where to find the issue
tracker. Provide the full URL. This is especially important if the
issue tracker should move again.

PR-URL: https://github.com/nodejs/node/pull/34686
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Ricky Zhou <0x19951125@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Mary Marchini <oss@mmarchini.me>
Reviewed-By: Denys Otrishko <shishugi@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
This commit is contained in:
Rich Trott
2020-08-08 16:39:05 -07:00
parent bcfb1762a3
commit 8a8416f841
2 changed files with 8 additions and 5 deletions

View File

@@ -201,7 +201,8 @@ function initEventTarget(self) {
class EventTarget {
// Used in checking whether an object is an EventTarget. This is a well-known
// symbol as EventTarget may be used cross-realm. See discussion in #33661.
// symbol as EventTarget may be used cross-realm.
// Ref: https://github.com/nodejs/node/pull/33661
static [kIsEventTarget] = true;
constructor() {
@@ -520,8 +521,8 @@ function validateEventListenerOptions(options) {
// Test whether the argument is an event object. This is far from a fool-proof
// test, for example this input will result in a false positive:
// > isEventTarget({ constructor: EventTarget })
// It stands in its current implementation as a compromise. For the relevant
// discussion, see #33661.
// It stands in its current implementation as a compromise.
// Ref: https://github.com/nodejs/node/pull/33661
function isEventTarget(obj) {
return obj && obj.constructor && obj.constructor[kIsEventTarget];
}

View File

@@ -208,7 +208,8 @@ function onStreamRead(arrayBuffer) {
}
if (nread !== UV_EOF) {
// #34375 CallJSOnreadMethod expects the return value to be a buffer.
// CallJSOnreadMethod expects the return value to be a buffer.
// Ref: https://github.com/nodejs/node/pull/34375
stream.destroy(errnoException(nread, 'read'));
return;
}
@@ -228,7 +229,8 @@ function onStreamRead(arrayBuffer) {
if (handle.readStop) {
const err = handle.readStop();
if (err) {
// #34375 CallJSOnreadMethod expects the return value to be a buffer.
// CallJSOnreadMethod expects the return value to be a buffer.
// Ref: https://github.com/nodejs/node/pull/34375
stream.destroy(errnoException(err, 'read'));
return;
}