From: Sam Reed Date: Sat, 25 Sep 2010 16:45:41 +0000 (+0000) Subject: Fill in missing params from a dieUsage X-Git-Tag: 1.31.0-rc.0~34798 X-Git-Url: http://git.cyclocoop.org/%22%20.%20generer_url_ecrire%28%22suivi_revisions%22%2C%22id_auteur=%24connecte%22%29%20.%20%22?a=commitdiff_plain;h=6c1273bc7d04daca0df5b48bbb7a90b3ee159fa0;p=lhc%2Fweb%2Fwiklou.git Fill in missing params from a dieUsage Braces Fixup parameter documentation --- diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index 7a861f303e..05521cb2a8 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -3086,7 +3086,7 @@ function &wfGetLBFactory() { /** * Find a file. * Shortcut for RepoGroup::singleton()->findFile() - * @param $title Either a string or Title object + * @param $title String or Title object * @param $options Associative array of options: * time: requested time for an archived image, or false for the * current version. An image object will be returned which was diff --git a/includes/api/ApiBase.php b/includes/api/ApiBase.php index 600dd508b6..9ef45ef916 100644 --- a/includes/api/ApiBase.php +++ b/includes/api/ApiBase.php @@ -589,7 +589,7 @@ abstract class ApiBase { * Set a watch (or unwatch) based the based on a watchlist parameter. * @param $watch String Valid values: 'watch', 'unwatch', 'preferences', 'nochange' * @param $titleObj Title the article's title to change - * @param $userOption The user option to consider when $watch=preferences + * @param $userOption String The user option to consider when $watch=preferences */ protected function setWatch ( $watch, $titleObj, $userOption = null ) { $value = $this->getWatchlistValue( $watch, $titleObj, $userOption ); diff --git a/includes/api/ApiMain.php b/includes/api/ApiMain.php index a6d44a3e34..1cf0281a1b 100644 --- a/includes/api/ApiMain.php +++ b/includes/api/ApiMain.php @@ -637,7 +637,9 @@ class ApiMain extends ApiBase { $this->checkExecutePermissions( $module ); - if ( !$this->checkMaxLag( $module, $params ) ) return; + if ( !$this->checkMaxLag( $module, $params ) ) { + return; + } if ( !$this->mInternalMode ) { $this->setupExternalResponse( $module, $params ); diff --git a/includes/api/ApiUpload.php b/includes/api/ApiUpload.php index af08a62497..f64cb37419 100644 --- a/includes/api/ApiUpload.php +++ b/includes/api/ApiUpload.php @@ -116,7 +116,7 @@ class ApiUpload extends ApiBase { // Status request for an async upload $sessionData = UploadFromUrlJob::getSessionData( $this->mParams['statuskey'] ); if ( !isset( $sessionData['result'] ) ) { - $this->dieUsage(); + $this->dieUsage( 'No result in session data', 'missingresult'); } if ( $sessionData['result'] == 'Warning' ) { $sessionData['warnings'] = $this->transformWarnings( $sessionData['warnings'] );