From 196dbbcad4d0b1b2c744b70a4c9548e3ec06c510 Mon Sep 17 00:00:00 2001 From: Heng Sin Low Date: Thu, 9 Apr 2009 07:09:49 +0000 Subject: [PATCH] minor - added NPE check --- .../src/org/adempiere/webui/panel/TreeSearchPanel.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/zkwebui/WEB-INF/src/org/adempiere/webui/panel/TreeSearchPanel.java b/zkwebui/WEB-INF/src/org/adempiere/webui/panel/TreeSearchPanel.java index 7fdd7cd82c..48f8529692 100644 --- a/zkwebui/WEB-INF/src/org/adempiere/webui/panel/TreeSearchPanel.java +++ b/zkwebui/WEB-INF/src/org/adempiere/webui/panel/TreeSearchPanel.java @@ -175,7 +175,9 @@ public class TreeSearchPanel extends Panel implements EventListener, TreeDataLis String value = cmbSearch.getValue(); Object node = treeNodeItemMap.get(value); Treeitem treeItem = null; - if (node instanceof Treeitem) { + if (node == null) { + return; + } else if (node instanceof Treeitem) { treeItem = (Treeitem) node; } else { SimpleTreeNode sNode = (SimpleTreeNode) node;