r58536 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r58535‎ | r58536 | r58537 >
Date:12:53, 4 November 2009
Author:btongminh
Status:ok (Comments)
Tags:
Comment:
* Disable autofill for reuploads
* Fix UploadFromStash::initialize parameters
Modified paths:
  • /trunk/phase3/includes/specials/SpecialUpload.php (modified) (history)
  • /trunk/phase3/includes/upload/UploadFromStash.php (modified) (history)
  • /trunk/phase3/languages/messages/MessagesEn.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/upload/UploadFromStash.php
@@ -27,7 +27,7 @@
2828 /*
2929 * some $na vars for uploadBase method compatibility.
3030 */
31 - public function initialize( $name, $sessionData, $na, $na2=false ) {
 31+ public function initialize( $name, $sessionData, $na=false, $na2=false ) {
3232 /**
3333 * Confirming a temporarily stashed upload.
3434 * We don't want path names to be forged, so we keep
Index: trunk/phase3/includes/specials/SpecialUpload.php
@@ -887,7 +887,7 @@
888888 * @param bool $autofill Whether or not to autofill the destination
889889 * filename text box
890890 */
891 - protected function addUploadJS( $autofill = true ) {
 891+ protected function addUploadJS( ) {
892892 global $wgUseAjax, $wgAjaxUploadDestCheck, $wgAjaxLicensePreview;
893893 global $wgEnableFirefogg, $wgEnableJS2system;
894894 global $wgOut;
@@ -899,7 +899,7 @@
900900 'wgAjaxUploadDestCheck' => $wgUseAjax && $wgAjaxUploadDestCheck,
901901 'wgAjaxLicensePreview' => $wgUseAjax && $wgAjaxLicensePreview,
902902 'wgEnableFirefogg' => (bool)$wgEnableFirefogg,
903 - 'wgUploadAutoFill' => (bool)$autofill,
 903+ 'wgUploadAutoFill' => !$this->mForReUpload,
904904 'wgUploadSourceIds' => $this->mSourceIds,
905905 );
906906
Index: trunk/phase3/languages/messages/MessagesEn.php
@@ -2683,7 +2683,7 @@
26842684 'protectexpiry' => 'Expires:',
26852685 'protect_expiry_invalid' => 'Expiry time is invalid.',
26862686 'protect_expiry_old' => 'Expiry time is in the past.',
2687 -'protect-unchain' => 'Unlock move permissions',
 2687+'protect-unchain-permissions' => 'Unlock further protect options',
26882688 'protect-text' => "You may view and change the protection level here for the page '''<nowiki>$1</nowiki>'''.",
26892689 'protect-locked-blocked' => "You cannot change protection levels while blocked.
26902690 Here are the current settings for the page '''$1''':",

Follow-up revisions

RevisionCommit summaryAuthorDate
r58537* (bug 6579) Fixed protecting images from uploading only...btongminh12:55, 4 November 2009

Comments

#Comment by Bryan (talk | contribs)   12:56, 4 November 2009

MessagesEn.php commit belongs to r58537.

#Comment by Raymond (talk | contribs)   15:14, 4 November 2009

Seen at translatewiki after reupload http://translatewiki.net/wiki/File:Wildkatze.jpg

PHP Strict Standards: Declaration of UploadFromStash::initialize() should be compatible with that of UploadBase::initialize() in /var/www/w/includes/upload/UploadFromStash.php on line 85

Status & tagging log