ApiScribuntoConsole: Don't use $wgUser

Change-Id: I41d9b0961e98d7836e8d5e8236ec2503f30713b1
This commit is contained in:
Kunal Mehta 2016-09-13 17:03:11 -07:00
parent f657c04653
commit b21cecbac1

View file

@ -22,8 +22,7 @@ class ApiScribuntoConsole extends ApiBase {
$sessionId = mt_rand( 0, 0x7fffffff );
}
global $wgUser;
$sessionKey = wfMemcKey( 'scribunto-console', $wgUser->getId(), $sessionId );
$sessionKey = wfMemcKey( 'scribunto-console', $this->getUser()->getId(), $sessionId );
$cache = ObjectCache::getInstance( CACHE_ANYTHING );
$session = null;
$sessionIsNew = false;