Skip to content

Commit

Permalink
Update retry.go
Browse files Browse the repository at this point in the history
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
  • Loading branch information
shogo82148 and coderabbitai[bot] authored Jun 18, 2024
1 parent 0163529 commit a9c39c4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions retry.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ func (p *Policy) Do(ctx context.Context, f func() error) error {
return err
}
if err, ok := err.(*temporaryError); ok {
// Unwrap the error if it's marked as temporary.
return err.error
}
return err
Expand Down

0 comments on commit a9c39c4

Please sign in to comment.