You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.
zone.js wrappes the removeAllListeners call from node.js but breaks compatibility with the real version.
This happens because zone.js parsed undefined arguments to the real call when none should be.
This causes the line highlighted below to fail since node.js tests on arguments.length
// ...EventEmitter.prototype.removeAllListeners=functionremoveAllListeners(type){varlisteners,events;events=this._events;if(!events)returnthis;// not listening for removeListener, no need to emitif(!events.removeListener){if(arguments.length===0){// <--- length will always be 2, since undefined is always passedthis._events=newEventHandlers();this._eventsCount=0;}elseif(events[type]){if(--this._eventsCount===0)this._events=newEventHandlers();elsedeleteevents[type];}returnthis;}// ...
The function is used by xml2js to remove all event listeners by calling: removeAllListeners() without arguments
The text was updated successfully, but these errors were encountered:
zone.js wrappes the removeAllListeners call from node.js but breaks compatibility with the real version.
This happens because zone.js parsed undefined arguments to the real call when none should be.
This causes the line highlighted below to fail since node.js tests on arguments.length
link to the faulting line in utils.ts:
https://github.com/angular/zone.js/blob/master/lib/common/utils.ts#L293
snippet form events.js in node 6.9.1
The function is used by
xml2j
s to remove all event listeners by calling:removeAllListeners()
without argumentsThe text was updated successfully, but these errors were encountered: