mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Cite
synced 2024-11-27 16:30:12 +00:00
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:
parent
8f3369b090
commit
f7bc278673
|
@ -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;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue