No need to set _index to null since Base.splice() handles that for us.

This commit is contained in:
Jürg Lehni 2011-05-15 21:42:31 +01:00
parent 9c97e44207
commit 0dc2241a9c
2 changed files with 2 additions and 2 deletions

View file

@ -118,7 +118,7 @@ var Document = this.Document = Base.extend({
remove: function() {
var res = Base.splice(this._scope.documents, null, this._index, 1);
this._scope = this._index = null;
this._scope = null;
return !!res.length;
},

View file

@ -289,7 +289,7 @@ var Item = this.Item = Base.extend({
if (this._name)
this._removeFromNamed();
var res = Base.splice(this._parent._children, null, this._index, 1);
this._parent = this._index = null;
this._parent = null;
return !!res.length;
}
return false;