Topic on Extension talk:Semantic ACL

wgParser has been depricated

3
Summary by Tinss

Corrected.

TazzyTazzy (talkcontribs)

Upgrading to MediaWiki 1361, and getting this error:

Use of $wgParser was deprecated in MediaWiki 1.32. [Called from MediaWiki\Extension\SemanticACL\SemanticACL::hasPermission in /var/www/mediawiki1362/extensions/SemanticACL/SemanticACL.class.php at line 303]


Per the mediawiki manual (Manual:$wgParser), it's a simple change.

I've replaced:

global $wgParser;


with:


$wgParser = new StubObject( 'wgParser', $wgParserConf['class'], array( $wgParserConf ) );


However, I don't know where to send a pull request to.


-Mitch

Tinss (talkcontribs)

Hello Mitch,

Thanks for pointing this out.

Per Manual:$wgParser, you should rather use \MediaWiki\MediaWikiServices::getInstance()->getParser().

Morevover the code for this extension si hosted in Wikimedia's gerrit. Any change you could push a commit for review there?

TazzyTazzy (talkcontribs)

I'll tackle these after vacation. :-)