child_process: give names to ChildProcess
functions
PR-URL: https://github.com/nodejs/node/pull/58370 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com> Reviewed-By: Jordan Harband <ljharb@gmail.com> Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com>
This commit is contained in:
parent
0e72f3b715
commit
8d603d540d
@ -352,7 +352,7 @@ function closePendingHandle(target) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
ChildProcess.prototype.spawn = function(options) {
|
ChildProcess.prototype.spawn = function spawn(options) {
|
||||||
let i = 0;
|
let i = 0;
|
||||||
|
|
||||||
validateObject(options, 'options');
|
validateObject(options, 'options');
|
||||||
@ -490,7 +490,7 @@ function onSpawnNT(self) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
ChildProcess.prototype.kill = function(sig) {
|
ChildProcess.prototype.kill = function kill(sig) {
|
||||||
|
|
||||||
const signal = sig === 0 ? sig :
|
const signal = sig === 0 ? sig :
|
||||||
convertToValidSignal(sig === undefined ? 'SIGTERM' : sig);
|
convertToValidSignal(sig === undefined ? 'SIGTERM' : sig);
|
||||||
@ -524,12 +524,12 @@ ChildProcess.prototype[SymbolDispose] = function() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
ChildProcess.prototype.ref = function() {
|
ChildProcess.prototype.ref = function ref() {
|
||||||
if (this._handle) this._handle.ref();
|
if (this._handle) this._handle.ref();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
ChildProcess.prototype.unref = function() {
|
ChildProcess.prototype.unref = function unref() {
|
||||||
if (this._handle) this._handle.unref();
|
if (this._handle) this._handle.unref();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user