X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fsite%2FSiteList.php;h=a94aa0b93b477871467916b688a81a4ad77c42ab;hb=2e7f4e48735b0e916336d9166cb1ab1756e0fa9f;hp=dfe4ec5e0d19fa3634d42015fafee76fd56f72b9;hpb=926f665234e72ea5905bcb239d1f7a32b488f875;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/site/SiteList.php b/includes/site/SiteList.php index dfe4ec5e0d..a94aa0b93b 100644 --- a/includes/site/SiteList.php +++ b/includes/site/SiteList.php @@ -34,7 +34,7 @@ class SiteList extends GenericArrayObject { * * @var array Array of integer */ - protected $byInternalId = array(); + protected $byInternalId = []; /** * Global site identifiers pointing to their sites offset value. @@ -43,7 +43,7 @@ class SiteList extends GenericArrayObject { * * @var array Array of string */ - protected $byGlobalId = array(); + protected $byGlobalId = []; /** * Navigational site identifiers alias inter-language prefixes @@ -53,7 +53,7 @@ class SiteList extends GenericArrayObject { * * @var array Array of string */ - protected $byNavigationId = array(); + protected $byNavigationId = []; /** * @see GenericArrayObject::getObjectType @@ -175,7 +175,7 @@ class SiteList extends GenericArrayObject { * @return bool */ public function isEmpty() { - return $this->byGlobalId === array(); + return $this->byGlobalId === []; } /** @@ -277,7 +277,7 @@ class SiteList extends GenericArrayObject { $group = new self(); /** - * @var \Site $site + * @var Site $site */ foreach ( $this as $site ) { if ( $site->getGroup() === $groupName ) { @@ -319,15 +319,15 @@ class SiteList extends GenericArrayObject { * @return array */ protected function getSerializationData() { - //NOTE: When changing the structure, either implement unserialize() to handle the + // NOTE: When changing the structure, either implement unserialize() to handle the // old structure too, or update SERIAL_VERSION_ID to kill any caches. return array_merge( parent::getSerializationData(), - array( + [ 'internalIds' => $this->byInternalId, 'globalIds' => $this->byGlobalId, 'navigationIds' => $this->byNavigationId - ) + ] ); } @@ -350,9 +350,3 @@ class SiteList extends GenericArrayObject { return $serializationData; } } - -/** - * @deprecated - */ -class SiteArray extends SiteList { -}