From c4637d292f38218b351b15b53d7d589904538e28 Mon Sep 17 00:00:00 2001 From: Bryan Tong Minh Date: Wed, 4 Nov 2009 12:53:09 +0000 Subject: [PATCH] * Disable autofill for reuploads * Fix UploadFromStash::initialize parameters --- includes/specials/SpecialUpload.php | 4 ++-- includes/upload/UploadFromStash.php | 2 +- languages/messages/MessagesEn.php | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/includes/specials/SpecialUpload.php b/includes/specials/SpecialUpload.php index 13bf30106d..7f877ae99c 100644 --- a/includes/specials/SpecialUpload.php +++ b/includes/specials/SpecialUpload.php @@ -887,7 +887,7 @@ class UploadForm extends HTMLForm { * @param bool $autofill Whether or not to autofill the destination * filename text box */ - protected function addUploadJS( $autofill = true ) { + protected function addUploadJS( ) { global $wgUseAjax, $wgAjaxUploadDestCheck, $wgAjaxLicensePreview; global $wgEnableFirefogg, $wgEnableJS2system; global $wgOut; @@ -899,7 +899,7 @@ class UploadForm extends HTMLForm { 'wgAjaxUploadDestCheck' => $wgUseAjax && $wgAjaxUploadDestCheck, 'wgAjaxLicensePreview' => $wgUseAjax && $wgAjaxLicensePreview, 'wgEnableFirefogg' => (bool)$wgEnableFirefogg, - 'wgUploadAutoFill' => (bool)$autofill, + 'wgUploadAutoFill' => !$this->mForReUpload, 'wgUploadSourceIds' => $this->mSourceIds, ); diff --git a/includes/upload/UploadFromStash.php b/includes/upload/UploadFromStash.php index 38d99f7d78..96059ebae5 100644 --- a/includes/upload/UploadFromStash.php +++ b/includes/upload/UploadFromStash.php @@ -27,7 +27,7 @@ class UploadFromStash extends UploadBase { /* * some $na vars for uploadBase method compatibility. */ - public function initialize( $name, $sessionData, $na, $na2=false ) { + public function initialize( $name, $sessionData, $na=false, $na2=false ) { /** * Confirming a temporarily stashed upload. * We don't want path names to be forged, so we keep diff --git a/languages/messages/MessagesEn.php b/languages/messages/MessagesEn.php index cb5479edc5..4cdc5d1de2 100644 --- a/languages/messages/MessagesEn.php +++ b/languages/messages/MessagesEn.php @@ -2683,7 +2683,7 @@ See the [[Special:ProtectedPages|protected pages list]] for the list of currentl 'protectexpiry' => 'Expires:', 'protect_expiry_invalid' => 'Expiry time is invalid.', 'protect_expiry_old' => 'Expiry time is in the past.', -'protect-unchain' => 'Unlock move permissions', +'protect-unchain-permissions' => 'Unlock further protect options', 'protect-text' => "You may view and change the protection level here for the page '''$1'''.", 'protect-locked-blocked' => "You cannot change protection levels while blocked. Here are the current settings for the page '''$1''':", -- 2.20.1