浏览代码

Protect EventDispatcher against the closure circular reference bug

Tristan VALCKE 8 年之前
父节点
当前提交
b9de3e2c6c
共有 1 个文件被更改,包括 2 次插入2 次删除
  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 };