MCPcopy Index your code
hub / github.com/nodejs/node / ref

Method ref

lib/internal/timers.js:668–678  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

666 }
667
668 ref() {
669 if (this[kRefed] === false) {
670 this[kRefed] = true;
671
672 if (immediateInfo[kRefCount]++ === 0) {
673 // We need to use the binding as the receiver for fast API calls.
674 binding.toggleImmediateRef(true);
675 }
676 }
677 return this;
678 }
679
680 unref() {
681 if (this[kRefed] === true) {

Callers 1

constructorMethod · 0.95

Calls 1

toggleImmediateRefMethod · 0.80

Tested by

no test coverage detected