/**
* 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
* 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 );
$this->checkExecutePermissions( $module );
- if ( !$this->checkMaxLag( $module, $params ) ) return;
+ if ( !$this->checkMaxLag( $module, $params ) ) {
+ return;
+ }
if ( !$this->mInternalMode ) {
$this->setupExternalResponse( $module, $params );
// 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'] );