dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "output: Narrow Title type hint to LinkTarget"
[lhc/web/wiklou.git]
/
includes
/
specialpage
/
SpecialPage.php
diff --git
a/includes/specialpage/SpecialPage.php
b/includes/specialpage/SpecialPage.php
index
d7e39d5
..
ba8e318
100644
(file)
--- a/
includes/specialpage/SpecialPage.php
+++ b/
includes/specialpage/SpecialPage.php
@@
-278,7
+278,9
@@
class SpecialPage implements MessageLocalizer {
*/
public function isRestricted() {
// DWIM: If anons can do something, then it is not restricted
*/
public function isRestricted() {
// DWIM: If anons can do something, then it is not restricted
- return $this->mRestriction != '' && !User::groupHasPermission( '*', $this->mRestriction );
+ return $this->mRestriction != '' && !MediaWikiServices::getInstance()
+ ->getPermissionManager()
+ ->groupHasPermission( '*', $this->mRestriction );
}
/**
}
/**
@@
-290,7
+292,9
@@
class SpecialPage implements MessageLocalizer {
* @return bool Does the user have permission to view the page?
*/
public function userCanExecute( User $user ) {
* @return bool Does the user have permission to view the page?
*/
public function userCanExecute( User $user ) {
- return $user->isAllowed( $this->mRestriction );
+ return MediaWikiServices::getInstance()
+ ->getPermissionManager()
+ ->userHasRight( $user, $this->mRestriction );
}
/**
}
/**