*/
protected $isSlotDiffRenderer = false;
- /**#@-*/
+ /** #@- */
/**
* @param IContextSource|null $context Context to use, anything else will be ignored
* @return string|bool Link HTML or false
*/
public function deletedLink( $id ) {
- if ( $this->getUser()->isAllowed( 'deletedhistory' ) ) {
+ $permissionManager = MediaWikiServices::getInstance()->getPermissionManager();
+ if ( $permissionManager->userHasRight( $this->getUser(), 'deletedhistory' ) ) {
$dbr = wfGetDB( DB_REPLICA );
$arQuery = Revision::getArchiveQueryInfo();
$row = $dbr->selectRow(
// Build the link
if ( $rcid ) {
$this->getOutput()->preventClickjacking();
- if ( $user->isAllowed( 'writeapi' ) ) {
+ if ( MediaWikiServices::getInstance()->getPermissionManager()
+ ->userHasRight( $user, 'writeapi' ) ) {
$this->getOutput()->addModules( 'mediawiki.page.patrol.ajax' );
}