ClientRequest.method->create

ClientRequest.method was deprecated in favor of the create method

Closes gh-17054
This commit is contained in:
Rob Winch 2025-05-06 11:06:26 -05:00
parent 11105a5c51
commit b467c47ed5
No known key found for this signature in database

View File

@ -161,7 +161,7 @@ final class HtmlUnitWebTestClient {
redirectUrl = scheme + "://" + host + location.toASCIIString();
}
// @formatter:off
ClientRequest redirect = ClientRequest.method(HttpMethod.GET, URI.create(redirectUrl))
ClientRequest redirect = ClientRequest.create(HttpMethod.GET, URI.create(redirectUrl))
.headers((headers) -> headers.addAll(request.headers()))
.cookies((cookies) -> cookies.addAll(request.cookies()))
.attributes((attributes) -> attributes.putAll(request.attributes()))