Skip to content

Commit c483e6d

Browse files
committed
events: convert errorMonitor to a normal property
Convert property errorMonitor to a normal property as non-writable caused unwanted side effects. Refs: nodejs#30932 (comment)
1 parent 1c14d65 commit c483e6d

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

lib/events.js

+1-6
Original file line numberDiff line numberDiff line change
@@ -89,12 +89,7 @@ ObjectDefineProperty(EventEmitter, 'captureRejections', {
8989
enumerable: true
9090
});
9191

92-
ObjectDefineProperty(EventEmitter, 'errorMonitor', {
93-
value: kErrorMonitor,
94-
writable: false,
95-
configurable: true,
96-
enumerable: true
97-
});
92+
EventEmitter.errorMonitor = kErrorMonitor;
9893

9994
// The default for captureRejections is false
10095
ObjectDefineProperty(EventEmitter.prototype, kCapture, {

0 commit comments

Comments
 (0)