Explorar o código

Protect EventDispatcher against the closure circular reference bug

Tristan VALCKE %!s(int64=8) %!d(string=hai) anos
pai
achega
b9de3e2c6c
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/core/EventDispatcher.js

+ 2 - 2
src/core/EventDispatcher.js

@@ -4,7 +4,7 @@
 
 function EventDispatcher() {}
 
-EventDispatcher.prototype = {
+Object.assign( EventDispatcher.prototype, {
 
 	addEventListener: function ( type, listener ) {
 
@@ -87,7 +87,7 @@ EventDispatcher.prototype = {
 
 	}
 
-};
+} );
 
 
 export { EventDispatcher };