summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb
diff options
context:
space:
mode:
authorAlexander Narsudinov <a.narsudinov@gmail.com>2022-12-17 17:24:10 +0300
committerAndreas Kling <kling@serenityos.org>2022-12-17 18:27:57 +0100
commitce6cf5bab8322412c14aa8a273f1fa4714769248 (patch)
tree77ba1bbd4544098ae0c1b538de28d967b3fd91b2 /Userland/Libraries/LibWeb
parent1a0fbe1e857018b3dc77c8319c54529cae9ffc90 (diff)
downloadserenity-ce6cf5bab8322412c14aa8a273f1fa4714769248.zip
LibWeb: Make method NamedNodeMap::set_attribute() closer to the spec
This patch eliminates 1 FIXME that I've got during fixme roulette! :^)
Diffstat (limited to 'Userland/Libraries/LibWeb')
-rw-r--r--Userland/Libraries/LibWeb/DOM/NamedNodeMap.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/Userland/Libraries/LibWeb/DOM/NamedNodeMap.cpp b/Userland/Libraries/LibWeb/DOM/NamedNodeMap.cpp
index e121b3f1b9..5ba887d206 100644
--- a/Userland/Libraries/LibWeb/DOM/NamedNodeMap.cpp
+++ b/Userland/Libraries/LibWeb/DOM/NamedNodeMap.cpp
@@ -168,9 +168,8 @@ WebIDL::ExceptionOr<Attr const*> NamedNodeMap::set_attribute(Attr& attribute)
return WebIDL::InUseAttributeError::create(realm(), "Attribute must not already be in use"sv);
// 2. Let oldAttr be the result of getting an attribute given attr’s namespace, attr’s local name, and element.
- // FIXME: When getNamedItemNS is implemented, use that instead.
size_t old_attribute_index = 0;
- auto* old_attribute = get_attribute(attribute.local_name(), &old_attribute_index);
+ auto* old_attribute = get_attribute_ns(attribute.namespace_uri(), attribute.local_name(), &old_attribute_index);
// 3. If oldAttr is attr, return attr.
if (old_attribute == &attribute)