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

LibWeb: Make XHR.response an actual XMLDocument for XML documents

Before this change, we were producing a generic DOM::Document, which
was not distinguishable from an XMLDocument by IDL interface type.
This commit is contained in:
Andreas Kling 2023-10-07 08:11:18 +02:00
parent 2b343c9508
commit 0762388709
5 changed files with 29 additions and 2 deletions

View file

@ -9,6 +9,11 @@
namespace Web::DOM {
JS::NonnullGCPtr<XMLDocument> XMLDocument::create(JS::Realm& realm, AK::URL const& url)
{
return realm.heap().allocate<XMLDocument>(realm, realm, url);
}
XMLDocument::XMLDocument(JS::Realm& realm, AK::URL const& url)
: Document(realm, url)
{