From e63578ff8383c6fb7aea06fa6cde5158fff43cbf Mon Sep 17 00:00:00 2001 From: GongWilliam <42128779+GongWilliam@users.noreply.github.com> Date: Wed, 27 Sep 2023 06:37:47 +0000 Subject: [PATCH] remove unnecessary variable in stepWithWaitOption --- node.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/node.go b/node.go index fe8f8dee..021adcf8 100644 --- a/node.go +++ b/node.go @@ -516,13 +516,12 @@ func (n *node) stepWithWaitOption(ctx context.Context, m pb.Message, wait bool) return ErrStopped } } - ch := n.propc pm := msgWithResult{m: m} if wait { pm.result = make(chan error, 1) } select { - case ch <- pm: + case n.propc <- pm: if !wait { return nil }