www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 6afce0cf220bb4ed589239e63e3b87c1a74332fc
parent 10181f7f56b1aa2b9f3d14a8603a09ad94fe8ade
Author: Dan Stillman <dstillman@zotero.org>
Date:   Sat, 30 Apr 2016 17:12:56 -0400

Fix "treeRow is undefined" error dragging to bottom of collections list

If you drag past the collections list the row is -1.

Fixes #958

Diffstat:
Mchrome/content/zotero/xpcom/collectionTreeView.js | 5+++++
1 file changed, 5 insertions(+), 0 deletions(-)

diff --git a/chrome/content/zotero/xpcom/collectionTreeView.js b/chrome/content/zotero/xpcom/collectionTreeView.js @@ -1432,6 +1432,11 @@ Zotero.CollectionTreeView.prototype.canDropCheck = function (row, orient, dataTr var dataType = dragData.dataType; var data = dragData.data; + // Empty space below rows + if (row == -1) { + return false; + } + // For dropping collections onto root level if (orient == 1 && row == 0 && dataType == 'zotero/collection') { return true;