Skip to content

Commit

Permalink
doc fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Jan Seidl committed Oct 9, 2020
1 parent d5890ce commit bf0c2cc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,9 @@ func Context(ctx context.Context) Option
```
Context allow to set context of retry default are Background context

example of immediately cancellation (maybe it isn't the best example, but it describes behavior enough; I hope)
example of immediately cancellation (maybe it isn't the best example, but it
describes behavior enough; I hope)

ctx, cancel := context.WithCancel(context.Background())
cancel()

Expand Down
3 changes: 2 additions & 1 deletion options.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,8 @@ func RetryIf(retryIf RetryIfFunc) Option {
// Context allow to set context of retry
// default are Background context
//
// example of immediately cancellation (maybe it isn't the best example, but it describes behavior enough; I hope)
// example of immediately cancellation (maybe it isn't the best example, but it describes behavior enough; I hope)
//
// ctx, cancel := context.WithCancel(context.Background())
// cancel()
//
Expand Down

0 comments on commit bf0c2cc

Please sign in to comment.