summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/Fetch/Body.cpp
AgeCommit message (Collapse)Author
2023-02-18LibWeb: Make factory method of FileAPI::Blob fallibleKenneth Myhra
2023-02-17LibJS+Everywhere: Convert JS::Error to StringTimothy Flynn
This includes an Error::create overload to create an Error from a UTF-8 StringView. If creating a String from that view fails, the factory will return an OOM InternalError instead. VM::throw_completion can also make use of this overload via its perfect forwarding.
2023-01-22LibJS+LibWeb: Convert empty PrimitiveString invocators to StringTimothy Flynn
2023-01-08LibJS+Everywhere: Make PrimitiveString and Utf16String fallibleTimothy Flynn
This makes construction of Utf16String fallible in OOM conditions. The immediate impact is that PrimitiveString must then be fallible as well, as it may either transcode UTF-8 to UTF-16, or create a UTF-16 string from ropes. There are a couple of places where it is very non-trivial to propagate the error further. A FIXME has been added to those locations.
2023-01-08LibJS+LibWeb: Move the macro to convert ENOMEM to an exception to LibJSTimothy Flynn
Move the macro to LibJS and change it to return a throw completion instead of a WebIDL exception. This will let us use this macro within LibJS to handle OOM conditions.
2022-12-07LibJS: Replace standalone js_string() with PrimitiveString::create()Linus Groh
Note that js_rope_string() has been folded into this, the old name was misleading - it would not always create a rope string, only if both sides are not empty strings. Use a three-argument create() overload instead.
2022-12-06Everywhere: Rename to_{string => deprecated_string}() where applicableLinus Groh
This will make it easier to support both string types at the same time while we convert code, and tracking down remaining uses. One big exception is Value::to_string() in LibJS, where the name is dictated by the ToString AO.
2022-12-06AK+Everywhere: Rename String to DeprecatedStringLinus Groh
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
2022-11-23LibJS+LibWeb: Make Runtime/AbstractOperations.h not include AST.hAndreas Kling
This led to considerable fallout and many files had to be patched with now-missing include statements.
2022-10-02LibJS: Make PromiseCapability GC-allocatedLinus Groh
A struct with three raw pointers to other GC'd types is a pretty big liability, let's just turn this into a Cell itself. This comes with the additional benefit of being able to capture it in a lambda effortlessly, without having to create handles for individual members.
2022-10-02LibJS: Move PromiseCapability into its own cpp/h fileLinus Groh
This is not strictly connected to PromiseReaction in any way. Preparation before doing some actual work on it :^)
2022-10-01LibWeb: Cleanup unecessary uses and includes of HTML::WindowAndrew Kaster
The big global refactor left some stragglers behind for atomicity. Clean up the rest, and remove a ton of includes of LibWeb/HTML/Window.h
2022-10-01LibWeb: Remove unecessary dependence on Window from Fetch, XHR, FileAPIAndrew Kaster
These classes only needed Window to get at its realm. Pass a realm directly to construct Fetch, XMLHttpRequest and FileAPI classes.
2022-09-27LibWeb: Implement '5.3. Body mixin' from the Fetch API :^)Linus Groh
This will be used to share functionality between Request and Response.