1
0
Fork 0
mirror of https://github.com/LadybirdBrowser/ladybird.git synced 2025-06-12 02:30:30 +09:00

LibProtocol: Use URL class in RequestClient::start_request argument

This changes the RequestClient::start_request() method to take a URL
object instead of a URL string as argument. All callers of the method
already had a URL object anyway, and start_request() in turn parses the
URL string back into a URL object. This removes this unnecessary
conversion.
This commit is contained in:
Max Wipfli 2021-06-05 11:59:04 +02:00 committed by Andreas Kling
parent 5b5f7bc360
commit 30cdebfa9e
Notes: sideshowbarker 2024-07-18 12:46:18 +09:00
5 changed files with 7 additions and 7 deletions

View file

@ -156,7 +156,7 @@ void ResourceLoader::load(const LoadRequest& request, Function<void(ReadonlyByte
headers.set(it.key, it.value);
}
auto protocol_request = protocol_client().start_request(request.method(), url.to_string(), headers, request.body());
auto protocol_request = protocol_client().start_request(request.method(), url, headers, request.body());
if (!protocol_request) {
if (error_callback)
error_callback("Failed to initiate load", {});