Move Linker::formatTemplates() to separate class, remove global usage
authorKunal Mehta <legoktm@member.fsf.org>
Fri, 9 Sep 2016 05:56:07 +0000 (22:56 -0700)
committerKunal Mehta <legoktm@member.fsf.org>
Fri, 9 Sep 2016 05:56:57 +0000 (22:56 -0700)
commitb16f897a05907698abb18af037688dde221575df
tree31814227e2ac92f49535350aa75967956ccb69b8
parent5d52874ddf5e2d27e0f256033f3e90a676bf7169
Move Linker::formatTemplates() to separate class, remove global usage

Linker::formatTemplates() was a static function that depended upon
global state like $wgLang (explicitly), $wgUser & $wgTitle (implicitly).
Moving it to a separate class allows us to clean it up a little bit and
use modern things like RequestContext and LinkRenderer.

Bug: T145177
Change-Id: Icdea8a2b299b4876feb3df3d66df3e4c104dd928
autoload.php
includes/DummyLinker.php
includes/EditPage.php
includes/Linker.php
includes/TemplatesOnThisPageFormatter.php [new file with mode: 0644]
includes/actions/InfoAction.php