Skip to content

Commit 7227b38

Browse files
committed
Merge pull request #10 from tkawachi/readme
Fixed README
2 parents c4e366c + d8b8d2d commit 7227b38

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ Retry provides a set of defaults that provide `retry.Success` definitions for [O
3737
import scala.concurrent.ExecutionContext.Implicits.global
3838
import scala.concurrent.Future
3939

40-
retry.Backoff()(Future {
40+
retry.Backoff()(() => Future {
4141
// something that can "fail"
4242
})
4343
```
@@ -93,7 +93,7 @@ after a failed attempt.
9393

9494
```scala
9595
// retry 4 times
96-
val future = retry.Directly(4) {
96+
val future = retry.Directly(4) { () =>
9797
attempt
9898
}
9999
```
@@ -104,7 +104,7 @@ The `retry.Pause` module defines interfaces for retrying a future with a configu
104104

105105
```scala
106106
// retry 3 times pausing 30 seconds in between attempts
107-
val future = retry.Pause(3, 30.seconds) {
107+
val future = retry.Pause(3, 30.seconds) { () =>
108108
attempt
109109
}
110110
```
@@ -118,7 +118,7 @@ backoff factor.
118118
```scala
119119
// retry 4 times with a delay of 1 second which will be multipled
120120
// by 2 on every attempt
121-
val future = retry.Backoff(4, 1.second) {
121+
val future = retry.Backoff(4, 1.second) { () =>
122122
attempt
123123
}
124124
```

0 commit comments

Comments
 (0)