*/
private function preCacheMessages() {
if ( !isset( $this->message ) ) {
+ $this->message = [];
foreach ( [
'cur', 'diff', 'hist', 'enhancedrc-history', 'last', 'blocklink', 'history',
'semicolon-separator', 'pipe-separator' ] as $msg
/** Check for rollback permissions, disallow special pages, and only
* show a link on the top-most revision
*/
- if ( $title->quickUserCan( 'rollback', $this->getUser() ) ) {
+ if ( MediaWikiServices::getInstance()->getPermissionManager()
+ ->quickUserCan( 'rollback', $this->getUser(), $title )
+ ) {
$rev = new Revision( [
'title' => $title,
'id' => $rc->mAttribs['rc_this_oldid'],