Skip to content

Commit

Permalink
fix: fixed check err
Browse files Browse the repository at this point in the history
  • Loading branch information
totanvix committed Jun 28, 2023
1 parent 246f1de commit 0b7330f
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions utils/bot/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,9 @@ func (b Bot) ResolveHook() error {
for {
select {
case r, ok := <-b.rCh:
if !ok {
return nil
if !ok || r.err != nil {
return r.err
}
return r.err
case <-time.After(10 * time.Second):
return errors.New("Timeout")
}
Expand Down

0 comments on commit 0b7330f

Please sign in to comment.