r33927 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r33926‎ | r33927 | r33928 >
Date:23:33, 26 April 2008
Author:aaron
Status:old
Tags:
Comment:
Make suppression require hiderevision
Modified paths:
  • /trunk/phase3/includes/Article.php (modified) (history)
  • /trunk/phase3/includes/FileDeleteForm.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Article.php
@@ -1992,7 +1992,7 @@
19931993 $reason = $this->DeleteReason;
19941994 }
19951995 # Flag to hide all contents of the archived revisions
1996 - $suppress = $wgRequest->getVal( 'wpSuppress' ) && $wgUser->isAllowed('deleterevision');
 1996+ $suppress = $wgRequest->getVal( 'wpSuppress' ) && $wgUser->isAllowed('hiderevision');
19971997
19981998 # This code desperately needs to be totally rewritten
19991999
@@ -2143,7 +2143,7 @@
21442144 $wgOut->setRobotpolicy( 'noindex,nofollow' );
21452145 $wgOut->addWikiMsg( 'confirmdeletetext' );
21462146
2147 - if( $wgUser->isAllowed( 'deleterevision' ) ) {
 2147+ if( $wgUser->isAllowed( 'hiderevision' ) ) {
21482148 $suppress = "<tr id=\"wpDeleteSuppressRow\" name=\"wpDeleteSuppressRow\"><td></td><td>";
21492149 $suppress .= Xml::checkLabel( wfMsg( 'revdelete-suppress' ), 'wpSuppress', 'wpSuppress', false, array( 'tabindex' => '2' ) );
21502150 $suppress .= "</td></tr>";
Index: trunk/phase3/includes/FileDeleteForm.php
@@ -45,7 +45,7 @@
4646 $this->oldimage = $wgRequest->getText( 'oldimage', false );
4747 $token = $wgRequest->getText( 'wpEditToken' );
4848 # Flag to hide all contents of the archived revisions
49 - $suppress = $wgRequest->getVal( 'wpSuppress' ) && $wgUser->isAllowed('deleterevision');
 49+ $suppress = $wgRequest->getVal( 'wpSuppress' ) && $wgUser->isAllowed('hiderevision');
5050
5151 if( $this->oldimage && !self::isValidOldSpec($this->oldimage) ) {
5252 $wgOut->showUnexpectedValueError( 'oldimage', htmlspecialchars( $this->oldimage ) );
@@ -126,7 +126,7 @@
127127 global $wgOut, $wgUser, $wgRequest, $wgContLang;
128128 $align = $wgContLang->isRtl() ? 'left' : 'right';
129129
130 - if( $wgUser->isAllowed( 'deleterevision' ) ) {
 130+ if( $wgUser->isAllowed( 'hiderevision' ) ) {
131131 $suppress = "<tr id=\"wpDeleteSuppressRow\" name=\"wpDeleteSuppressRow\"><td></td><td>";
132132 $suppress .= Xml::checkLabel( wfMsg( 'revdelete-suppress' ), 'wpSuppress', 'wpSuppress', false, array( 'tabindex' => '2' ) );
133133 $suppress .= "</td></tr>";

Status & tagging log