Skip to content

Commit

Permalink
idk how this accidentally got reverted 2 commits ago
Browse files Browse the repository at this point in the history
  • Loading branch information
wagyourtail committed Sep 23, 2024
1 parent aac58cb commit 7d4f4ca
Showing 1 changed file with 3 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,7 @@
import java.net.*;
import java.nio.ByteBuffer;
import java.time.Duration;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import java.util.*;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.Executor;
import java.util.concurrent.Flow;
Expand Down Expand Up @@ -187,7 +184,8 @@ public void onComplete() {
}

int responseCode = connection.getResponseCode();
Map<String, List<String>> headers = connection.getHeaderFields();
Map<String, List<String>> headers = new HashMap<>(connection.getHeaderFields());
headers.remove(null);
Version version = J_N_H_HttpClient.Version.HTTP_1_1;
HttpResponseInfo info = new HttpResponseInfo(responseCode, new J_N_H_HttpHeaders(headers), version);
J_N_H_HttpResponse.BodySubscriber<T> subscriber = handler.apply(info);
Expand Down

0 comments on commit 7d4f4ca

Please sign in to comment.