Fix for error when dragging an attachment that's the last item in a folder into another item

This commit is contained in:
Dan Stillman 2007-01-11 20:41:35 +00:00
parent 3bc1a28ce4
commit 417397c59f

View File

@ -756,7 +756,11 @@ Zotero.ItemTreeView.prototype.saveSelection = function()
this.selection.getRangeAt(i,start,end);
for (var j=start.value; j<=end.value; j++)
{
savedSelection.push(this._getItemAtRow(j).ref.getID());
var item = this._getItemAtRow(j);
if (!item) {
continue;
}
savedSelection.push(item.ref.getID());
}
}
return savedSelection;