1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:28:10 +00:00

LibWeb: Make URL, URLSearchParams & URLSearchParamsIterator GC-allocated

This commit is contained in:
Andreas Kling 2022-09-04 14:04:42 +02:00
parent 0dc2c27fa3
commit fe9c5395d4
11 changed files with 125 additions and 86 deletions

View file

@ -301,7 +301,7 @@ static ErrorOr<Fetch::Infrastructure::BodyWithType> extract_body(XMLHttpRequestB
source = TRY(Bindings::IDL::get_buffer_source_copy(*buffer_source.cell()));
return {};
},
[&](NonnullRefPtr<URL::URLSearchParams> const& url_search_params) -> ErrorOr<void> {
[&](JS::Handle<URL::URLSearchParams> const& url_search_params) -> ErrorOr<void> {
// Set source to the result of running the application/x-www-form-urlencoded serializer with objects list.
source = url_search_params->to_string().to_byte_buffer();
// Set type to `application/x-www-form-urlencoded;charset=UTF-8`.