domain: converted anonymous to named function
PR-URL: https://github.com/nodejs/node/pull/20021 Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
This commit is contained in:
parent
72549aa9cd
commit
ca41a30afa
@ -184,7 +184,7 @@ class Domain extends EventEmitter {
|
|||||||
|
|
||||||
exports.Domain = Domain;
|
exports.Domain = Domain;
|
||||||
|
|
||||||
exports.create = exports.createDomain = function() {
|
exports.create = exports.createDomain = function createDomain() {
|
||||||
return new Domain();
|
return new Domain();
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -193,7 +193,7 @@ exports.active = null;
|
|||||||
Domain.prototype.members = undefined;
|
Domain.prototype.members = undefined;
|
||||||
|
|
||||||
// Called by process._fatalException in case an error was thrown.
|
// Called by process._fatalException in case an error was thrown.
|
||||||
Domain.prototype._errorHandler = function _errorHandler(er) {
|
Domain.prototype._errorHandler = function(er) {
|
||||||
var caught = false;
|
var caught = false;
|
||||||
|
|
||||||
if (!util.isPrimitive(er)) {
|
if (!util.isPrimitive(er)) {
|
||||||
@ -428,7 +428,7 @@ EventEmitter.init = function() {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const eventEmit = EventEmitter.prototype.emit;
|
const eventEmit = EventEmitter.prototype.emit;
|
||||||
EventEmitter.prototype.emit = function emit(...args) {
|
EventEmitter.prototype.emit = function(...args) {
|
||||||
const domain = this.domain;
|
const domain = this.domain;
|
||||||
|
|
||||||
const type = args[0];
|
const type = args[0];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user