From ba2dd9385c2a51134e520083dc732787a813b107 Mon Sep 17 00:00:00 2001 From: SanYe Date: Fri, 15 Mar 2024 17:46:22 +0800 Subject: [PATCH] accounts/abi/bind: remove unused err set and check (#29269) accounts/abi: remove unused err set and check --- accounts/abi/bind/base.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/accounts/abi/bind/base.go b/accounts/abi/bind/base.go index 96d284cdcc..c8972a9dff 100644 --- a/accounts/abi/bind/base.go +++ b/accounts/abi/bind/base.go @@ -461,7 +461,7 @@ func (c *BoundContract) FilterLogs(opts *FilterOpts, name string, query ...[]int if err != nil { return nil, nil, err } - sub, err := event.NewSubscription(func(quit <-chan struct{}) error { + sub := event.NewSubscription(func(quit <-chan struct{}) error { for _, log := range buff { select { case logs <- log: @@ -470,11 +470,8 @@ func (c *BoundContract) FilterLogs(opts *FilterOpts, name string, query ...[]int } } return nil - }), nil + }) - if err != nil { - return nil, nil, err - } return logs, sub, nil }