X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FAutopromote.php;h=21567878868a0033194a713d604ec42f10df900e;hb=cb5acb42ce62b2d600dfb4e11a2982602b670a2f;hp=b17f1ab1c672e9362528cb40916ef87f91f016bc;hpb=5919c427f422b921b8aa2dfc5f3c725dfbba7d9a;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Autopromote.php b/includes/Autopromote.php index b17f1ab1c6..2156787886 100644 --- a/includes/Autopromote.php +++ b/includes/Autopromote.php @@ -21,6 +21,8 @@ * @file */ +use MediaWiki\MediaWikiServices; + /** * This class checks if user can get extra rights * because of conditions specified in $wgAutopromote @@ -200,7 +202,9 @@ class Autopromote { case APCOND_BLOCKED: return $user->getBlock() && $user->getBlock()->isSitewide(); case APCOND_ISBOT: - return in_array( 'bot', User::getGroupPermissions( $user->getGroups() ) ); + return in_array( 'bot', MediaWikiServices::getInstance() + ->getPermissionManager() + ->getGroupPermissions( $user->getGroups() ) ); default: $result = null; Hooks::run( 'AutopromoteCondition', [ $cond[0],