mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 11:55:56 +00:00
feedTree: amend previous to check that nodes are actually there
This commit is contained in:
@@ -276,9 +276,11 @@ define(["dojo/_base/declare", "dojo/dom-construct", "dijit/Tree", "dijit/Menu"],
|
||||
const node = treeNode.rowNode;
|
||||
const tree = this.domNode;
|
||||
|
||||
// scroll tree to selection if needed
|
||||
if (node.offsetTop < tree.scrollTop || node.offsetTop > tree.scrollTop + tree.clientHeight) {
|
||||
$("feedTree").scrollTop = node.offsetTop;
|
||||
if (node && tree) {
|
||||
// scroll tree to selection if needed
|
||||
if (node.offsetTop < tree.scrollTop || node.offsetTop > tree.scrollTop + tree.clientHeight) {
|
||||
$("feedTree").scrollTop = node.offsetTop;
|
||||
}
|
||||
}
|
||||
|
||||
}, 0);
|
||||
|
||||
Reference in New Issue
Block a user