Skip to content

Commit b90e911

Browse files
committed
Fix darn obvious backporting error
1 parent 548bb4a commit b90e911

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/extender.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -959,15 +959,15 @@ namespace Sass {
959959
if (innerPseudo->normalized() != "matches") return {};
960960
return innerPseudo->selector()->elements();
961961
}
962-
else if (name == "matches" && name == "any" && name == "current" && name == "nth-child" && name == "nth-last-child") {
962+
else if (name == "matches" || name == "any" || name == "current" || name == "nth-child" || name == "nth-last-child") {
963963
// As above, we could theoretically support :not within :matches, but
964964
// doing so would require this method and its callers to handle much
965965
// more complex cases that likely aren't worth the pain.
966966
if (innerPseudo->name() != pseudo->name()) return {};
967967
if (innerPseudo->argument() != pseudo->argument()) return {};
968968
return innerPseudo->selector()->elements();
969969
}
970-
else if (name == "has" && name == "host" && name == "host-context" && name == "slotted") {
970+
else if (name == "has" || name == "host" || name == "host-context" || name == "slotted") {
971971
// We can't expand nested selectors here, because each layer adds an
972972
// additional layer of semantics. For example, `:has(:has(img))`
973973
// doesn't match `<div><img></div>` but `:has(img)` does.

0 commit comments

Comments
 (0)