Minor fixes to Cite port

Change-Id: Iccd6823c572059948e5ad1a7c91d567d39494934
This commit is contained in:
Subramanya Sastry 2019-06-26 11:58:55 -05:00
parent 3f0b81b085
commit bc72a99fb2
2 changed files with 6 additions and 2 deletions

View file

@ -117,7 +117,8 @@ class RefGroup {
$li->insertBefore( $span, $reftextSpan );
foreach ( $ref->linkbacks as $i => $lb ) {
$span->appendChild( self::createLinkback( $lb, $refGroup, (string)( $i + 1 ), $ownerDoc, $env )
$span->appendChild(
self::createLinkback( $lb, $refGroup, (string)( $i + 1 ), $ownerDoc, $env )
);
}
}

View file

@ -185,7 +185,10 @@ class References implements ExtensionTag, SerialHandler {
]
);
DOMDataUtils::addTypeOf( $linkBack, 'mw:Extension/ref' );
$dataParsoid = (object)[ 'src' => $nodeDp->src ];
$dataParsoid = (object)[];
if ( isset( $nodeDp->src ) ) {
$dataParsoid->src = $nodeDp->src;
}
if ( isset( $nodeDp->dsr ) ) {
$dataParsoid->dsr = $nodeDp->dsr;
}