From 3a33ba5dad3c6307c74b859e8e9afe24b863a140 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Sun, 21 Jan 2024 14:43:46 -0600 Subject: minor changes Signed-off-by: Jeff Carr --- addNode.go | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'addNode.go') diff --git a/addNode.go b/addNode.go index 660ddae..2db130c 100644 --- a/addNode.go +++ b/addNode.go @@ -1,8 +1,6 @@ package tree import ( - "errors" - "go.wit.com/log" "go.wit.com/widget" ) @@ -35,9 +33,9 @@ func (me *TreeInfo) AddNode(a *widget.Action) *Node { p := me.treeRoot.FindWidgetId(a.ParentId) n.Parent = p if n.Parent == nil { - log.Error(errors.New("tree.AddNode() ERROR n.Parent == nil"), a.WidgetId, a.ParentId, a.ActionType) - log.Warn("AddNode() ERROR n.Parent == nil", a.WidgetId, a.ParentId, a.ActionType) - log.Warn("AddNode() ERROR n.Parent == nil", a.WidgetId, a.ParentId, a.WidgetType) + log.Log(TREEWARN, "AddNode() ERROR n.Parent == nil n =", n.WidgetId, n.WidgetType, n.GetProgName()) + log.Log(TREEWARN, "AddNode() ERROR n.Parent == nil a =", a.WidgetId, a.WidgetType, a.State.ProgName) + log.Log(TREEWARN, "AddNode() ERROR n.Parent == nil a.pid =", a.ParentId) return n } log.Log(TREE, "AddNode() Adding to parent =", p.ParentId, p.WidgetType, p.GetProgName()) -- cgit v1.2.3