* @file
* @ingroup Site
*
- * @license GNU GPL v2+
+ * @license GPL-2.0-or-later
* @author Daniel Kinzler
*/
class SiteImporter {
* @return Site[]
*/
private function makeSiteList( DOMElement $root ) {
- $sites = array();
+ $sites = [];
// Old sites, to get the row IDs that correspond to the global site IDs.
// TODO: Get rid of internal row IDs, they just get in the way. Get rid of ORMRow, too.
$pathTags = $siteElement->getElementsByTagName( 'path' );
for ( $i = 0; $i < $pathTags->length; $i++ ) {
$pathElement = $pathTags->item( $i );
+ '@phan-var DOMElement $pathElement';
$pathType = $this->getAttributeValue( $pathElement, 'type' );
$path = $pathElement->textContent;
$idTags = $siteElement->getElementsByTagName( 'localid' );
for ( $i = 0; $i < $idTags->length; $i++ ) {
$idElement = $idTags->item( $i );
+ '@phan-var DOMElement $idElement';
$idType = $this->getAttributeValue( $idElement, 'type' );
$id = $idElement->textContent;
/**
* @param DOMElement $element
- * @param $name
+ * @param string $name
* @param string|null|bool $default
*
* @return null|string