mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2024-11-21 16:27:39 -06:00
Fixed tree related issues.
This commit is contained in:
parent
dd6f6cf1af
commit
53760dbf59
@ -611,7 +611,9 @@ export class FileTreeX extends React.Component<IFileTreeXProps> {
|
||||
const scrollXPos = scrollX || 0;
|
||||
const scrollYPos = scrollY || this.props.model.state.scrollOffset;
|
||||
const div = this.wrapperRef.current.querySelector('div').querySelector('div') as HTMLDivElement;
|
||||
div.scroll(scrollXPos, scrollYPos);
|
||||
if (div) {
|
||||
div.scroll(scrollXPos, scrollYPos);
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
|
@ -477,7 +477,7 @@ export class Tree {
|
||||
let result = {};
|
||||
if (identifier === undefined) return;
|
||||
let item = TreeNode.prototype.isPrototypeOf(identifier) ? identifier : this.findNode(identifier.path);
|
||||
if (item === undefined) return;
|
||||
if (!item) return;
|
||||
do {
|
||||
const currentNodeData = item.getData();
|
||||
if (currentNodeData._type in this.Nodes && this.Nodes[currentNodeData._type].hasId) {
|
||||
|
Loading…
Reference in New Issue
Block a user