DOMUtils: Get rid of isElt, isText, isComment helpers

* Most of these are remnants from the Parsoid/JS codebase.
* This change follows the pattern we've been using everywhere
  since the port from JS->PHP.
* Also reduces instruction count by about 0.2%.

Change-Id: Ibf21104f6722c34299f03e303dc3401bf053a751
This commit is contained in:
Subramanya Sastry 2021-09-17 12:02:39 -05:00 committed by jenkins-bot
parent 8f3369b090
commit f7bc278673

View file

@ -24,7 +24,7 @@ class References extends ExtensionTagHandler {
private static function hasRef( Node $node ): bool {
$c = $node->firstChild;
while ( $c ) {
if ( DOMUtils::isElt( $c ) ) {
if ( $c instanceof Element ) {
if ( WTUtils::isSealedFragmentOfType( $c, 'ref' ) ) {
return true;
}