Skip to content

Commit 95b8b7e

Browse files
himself65RafaelGSS
authored andcommitted
domain: remove deprecated API call
PR-URL: #59339 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com>
1 parent db24174 commit 95b8b7e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/domain.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ Domain.prototype._errorHandler = function(er) {
270270
// as this would throw an error, make the process exit, and thus
271271
// prevent the process 'uncaughtException' event from being emitted
272272
// if a listener is set.
273-
if (EventEmitter.listenerCount(this, 'error') > 0) {
273+
if (this.listenerCount('error') > 0) {
274274
// Clear the uncaughtExceptionCaptureCallback so that we know that, since
275275
// the top-level domain is not active anymore, it would be ok to abort on
276276
// an uncaught exception at this point

0 commit comments

Comments
 (0)