Jump to content

Group.removeBetween has wrong default endIndex?


darfux
 Share

Recommended Posts

Hi,

When I using the Group.removeBetween(startIndex) to remove children from startIndex to the end of the Group, it always throws Uncaught TypeError: Cannot read property 'events' of undefined.It seems that the implemention of default endIndex is bugged? :

 

Group.js#line-1580

if (typeof endIndex === 'undefined') { endIndex = this.children.length; } 

Group.js#line-1594

var i = endIndex;while (i >= startIndex){    //The first children[i] is out of bounds?    if (!silent && this.children[i].events)    {        this.children[i].events.onRemovedFromGroup.dispatch(this.children[i], this);    }    var removed = this.removeChild(this.children[i]); 
Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...