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 "maintenance: Enable gzip in router.php for static files"
[lhc/web/wiklou.git]
/
includes
/
api
/
ApiQueryInfo.php
diff --git
a/includes/api/ApiQueryInfo.php
b/includes/api/ApiQueryInfo.php
index
50bd63f
..
98474c7
100644
(file)
--- a/
includes/api/ApiQueryInfo.php
+++ b/
includes/api/ApiQueryInfo.php
@@
-118,6
+118,7
@@
class ApiQueryInfo extends ApiQueryBase {
return $this->tokenFunctions;
}
return $this->tokenFunctions;
}
+ /** @var string[] */
protected static $cachedTokens = [];
/**
protected static $cachedTokens = [];
/**
@@
-250,7
+251,9
@@
class ApiQueryInfo extends ApiQueryBase {
*/
public static function getImportToken( $pageid, $title ) {
global $wgUser;
*/
public static function getImportToken( $pageid, $title ) {
global $wgUser;
- if ( !$wgUser->isAllowedAny( 'import', 'importupload' ) ) {
+ if ( !MediaWikiServices::getInstance()
+ ->getPermissionManager()
+ ->userHasAnyRight( $wgUser, 'import', 'importupload' ) ) {
return false;
}
return false;
}