Browse Source

fixed handle cleanup error

when cleanup return an error , why handle ‘err’ ( seem always nil ) ?
coldWater 6 years ago
parent
commit
b4d38af3f3
1 changed files with 1 additions and 1 deletions
  1. 1 1
      consumer_group.go

+ 1 - 1
consumer_group.go

@@ -614,7 +614,7 @@ func (s *consumerGroupSession) release(withCleanup bool) (err error) {
 	s.releaseOnce.Do(func() {
 		if withCleanup {
 			if e := s.handler.Cleanup(s); e != nil {
-				s.parent.handleError(err, "", -1)
+				s.parent.handleError(e, "", -1)
 				err = e
 			}
 		}