From 7caa9f5f505f97565cdac3f82a0b7d3d6df80a46 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Thu, 5 Nov 2015 15:40:10 +0100 Subject: [PATCH] Fix error on dragging when search in treelist is active --- program/js/treelist.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/program/js/treelist.js b/program/js/treelist.js index 9194d7b56..bcbfeebae 100644 --- a/program/js/treelist.js +++ b/program/js/treelist.js @@ -943,7 +943,7 @@ function rcube_treelist_widget(node, p) for (var id in indexbyid) { li = id2dom(id); item = li.children().first().get(0); - if (height = item.offsetHeight) { + if (item && (height = item.offsetHeight)) { pos = $(item).offset(); pos.top += list_scroll_top; item_coords[id] = {