We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b1a72ad commit 8ce7884Copy full SHA for 8ce7884
BunqSdk/Http/RetryHandler.cs
@@ -15,9 +15,8 @@ protected override Task<HttpResponseMessage> SendAsync(
15
CancellationToken cancellationToken) =>
16
Policy
17
.Handle<HttpRequestException>()
18
- .Or<TaskCanceledException>()
19
- .OrResult<HttpResponseMessage>(x => !x.IsSuccessStatusCode)
+ .OrResult<HttpResponseMessage>(x => x.StatusCode == (System.Net.HttpStatusCode)429)
20
.WaitAndRetryAsync(3, retryAttempt => TimeSpan.FromSeconds(Math.Pow(3, retryAttempt)))
21
.ExecuteAsync(() => base.SendAsync(request, cancellationToken));
22
}
23
-}
+}
0 commit comments