* @return mixed Property value or null if not found
*/
public function getProperty( $name ) {
- if ( isset( $this->mProperties[$name] ) ) {
- return $this->mProperties[$name];
- } else {
- return null;
- }
+ return $this->mProperties[$name] ?? null;
}
/**
);
# Add the results to the link cache
- $lb->addResultToCache( LinkCache::singleton(), $res );
+ $linkCache = MediaWikiServices::getInstance()->getLinkCache();
+ $lb->addResultToCache( $linkCache, $res );
return $res;
}