X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Flinker%2FLinkRendererFactory.php;h=eeb28b5560ccf1a05a467596a8a369446bb2672d;hb=e65f8ac5110804067366f9f239c13f4f29b66c3d;hp=240ea09be90cc2e85e2df299cb8f41766b5f0d04;hpb=3b87d31562a09951a8983759bfd857ffef8f7b6f;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/linker/LinkRendererFactory.php b/includes/linker/LinkRendererFactory.php index 240ea09be9..eeb28b5560 100644 --- a/includes/linker/LinkRendererFactory.php +++ b/includes/linker/LinkRendererFactory.php @@ -21,6 +21,7 @@ namespace MediaWiki\Linker; use LinkCache; +use NamespaceInfo; use TitleFormatter; use User; @@ -40,20 +41,29 @@ class LinkRendererFactory { */ private $linkCache; + /** + * @var NamespaceInfo + */ + private $nsInfo; + /** * @param TitleFormatter $titleFormatter * @param LinkCache $linkCache + * @param NamespaceInfo $nsInfo */ - public function __construct( TitleFormatter $titleFormatter, LinkCache $linkCache ) { + public function __construct( + TitleFormatter $titleFormatter, LinkCache $linkCache, NamespaceInfo $nsInfo + ) { $this->titleFormatter = $titleFormatter; $this->linkCache = $linkCache; + $this->nsInfo = $nsInfo; } /** * @return LinkRenderer */ public function create() { - return new LinkRenderer( $this->titleFormatter, $this->linkCache ); + return new LinkRenderer( $this->titleFormatter, $this->linkCache, $this->nsInfo ); } /**