1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 18:37:35 +00:00

LibWeb: Avoid QualifiedName copy when matching tag name selectors

This commit is contained in:
Andreas Kling 2023-11-02 08:09:01 +01:00
parent e4621704ce
commit 0e9bdfa822

View file

@ -542,7 +542,7 @@ static inline bool matches(CSS::Selector::SimpleSelector const& component, Optio
switch (component.type) {
case CSS::Selector::SimpleSelector::Type::Universal:
case CSS::Selector::SimpleSelector::Type::TagName: {
auto qualified_name = component.qualified_name();
auto const& qualified_name = component.qualified_name();
// Reject if the tag name doesn't match
if (component.type == CSS::Selector::SimpleSelector::Type::TagName) {