Improve variable naming
This commit is contained in:
parent
8d31540754
commit
4bd15ed2e7
1 changed files with 4 additions and 4 deletions
|
|
@ -63,13 +63,13 @@ class ApiComparePages extends ApiBase {
|
|||
* @param $title string
|
||||
* @return int
|
||||
*/
|
||||
private function revisionOrTitle( $revision, $title ) {
|
||||
private function revisionOrTitle( $revision, $titleText ) {
|
||||
if( $revision ){
|
||||
return $revision;
|
||||
} elseif( $title ) {
|
||||
$title = Title::newFromText( $title );
|
||||
} elseif( $titleText ) {
|
||||
$title = Title::newFromText( $titleText );
|
||||
if( !$title ){
|
||||
$this->dieUsageMsg( array( 'invalidtitle', $title ) );
|
||||
$this->dieUsageMsg( array( 'invalidtitle', $titleText ) );
|
||||
}
|
||||
return $title->getLatestRevID();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue