r79710 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79709‎ | r79710 | r79711 >
Date:03:27, 6 January 2011
Author:reedy
Status:ok
Tags:
Comment:
Fixup FIXME on r65818
Modified paths:
  • /trunk/phase3/includes/upload/UploadBase.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/upload/UploadBase.php
@@ -78,20 +78,12 @@
7979 }
8080
8181 /**
82 - * Returns an array of permissions that is required to upload a file
83 - *
84 - * @return array
85 - */
86 - public static function getRequiredPermissions() {
87 - return array( 'upload', 'edit' );
88 - }
89 - /**
9082 * Returns true if the user can use this upload module or else a string
9183 * identifying the missing permission.
9284 * Can be overriden by subclasses.
9385 */
9486 public static function isAllowed( $user ) {
95 - foreach ( self::getRequiredPermissions() as $permission ) {
 87+ foreach ( array( 'upload', 'edit' ) as $permission ) {
9688 if ( !$user->isAllowed( $permission ) ) {
9789 return $permission;
9890 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r797201.17: MFT r79578, r79591, r79593, r79595, r79649, r79650, r79651, r79653, r79...catrope14:48, 6 January 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r65818(bug 18408) All required permissions for uploading (upload, edit, create) are...btongminh20:34, 2 May 2010

Status & tagging log