Skip to content

Commit

Permalink
Update internal cast that went wrong
Browse files Browse the repository at this point in the history
  • Loading branch information
vietj committed Oct 3, 2023
1 parent 2563fe9 commit afed38f
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import io.vertx.core.http.HttpClientResponse;
import io.vertx.core.http.HttpHeaders;
import io.vertx.core.http.RequestOptions;
import io.vertx.core.http.impl.CleanableHttpClient;
import io.vertx.core.http.impl.HttpClientImpl;
import io.vertx.core.http.impl.HttpClientInternal;
import io.vertx.core.impl.ContextInternal;
Expand Down Expand Up @@ -264,7 +265,7 @@ public void receiveResponse(HttpClientResponse clientResponse) {
this.clientResponse = clientResponse;
if (redirects < maxRedirects && sc >= 300 && sc < 400) {
redirects++;
Future<RequestOptions> next = ((HttpClientImpl)client).redirectHandler().apply(clientResponse);
Future<RequestOptions> next = ((HttpClientImpl)((CleanableHttpClient)client).delegate).redirectHandler().apply(clientResponse);
if (next != null) {
if (redirectedLocations.isEmpty()) {
redirectedLocations = new ArrayList<>();
Expand Down

0 comments on commit afed38f

Please sign in to comment.