From e336b5e951ed31eef3ddeb9c2e4abbb06f070c34 Mon Sep 17 00:00:00 2001 From: Sam Reed Date: Tue, 18 Oct 2011 17:31:54 +0000 Subject: [PATCH] Remove some unused getting of non existent arguments Documentation --- maintenance/Maintenance.php | 6 ++ maintenance/backup.inc | 1 + maintenance/backupPrefetch.inc | 5 ++ maintenance/benchmarks/benchmarkPurge.php | 4 ++ maintenance/checkSyntax.php | 10 +++- maintenance/cleanupCaps.php | 3 +- maintenance/cleanupImages.php | 12 ++-- maintenance/cleanupUploadStash.php | 15 ++--- maintenance/dumpTextPass.php | 48 +++++++++------- maintenance/fuzz-tester.php | 70 +++++++++++++++-------- maintenance/generateSitemap.php | 5 ++ maintenance/importDump.php | 8 ++- maintenance/jsparse.php | 1 - maintenance/mwdocgen.php | 2 + 14 files changed, 127 insertions(+), 63 deletions(-) diff --git a/maintenance/Maintenance.php b/maintenance/Maintenance.php index 0dca74ad2d..95854b069a 100644 --- a/maintenance/Maintenance.php +++ b/maintenance/Maintenance.php @@ -526,6 +526,7 @@ abstract class Maintenance { * to allow sysadmins to explicitly set one if they'd prefer to override * defaults (or for people using Suhosin which yells at you for trying * to disable the limits) + * @return string */ public function memoryLimit() { $limit = $this->getOption( 'memory-limit', 'max' ); @@ -852,6 +853,9 @@ abstract class Maintenance { $wgDBpassword = $wgDBadminpassword; if ( $wgDBservers ) { + /** + * @var $wgDBservers array + */ foreach ( $wgDBservers as $i => $server ) { $wgDBservers[$i]['user'] = $wgDBuser; $wgDBservers[$i]['password'] = $wgDBpassword; @@ -980,6 +984,7 @@ abstract class Maintenance { /** * Get the maintenance directory. + * @return string */ protected function getDir() { return dirname( __FILE__ ); @@ -1127,6 +1132,7 @@ abstract class Maintenance { * Update the searchindex table for a given pageid * @param $dbw Database: a database write handle * @param $pageId Integer: the page ID to update. + * @return null|string */ public function updateSearchIndexForPage( $dbw, $pageId ) { // Get current revision diff --git a/maintenance/backup.inc b/maintenance/backup.inc index 0df553ea66..36c3beb573 100644 --- a/maintenance/backup.inc +++ b/maintenance/backup.inc @@ -252,6 +252,7 @@ class BackupDumper { * @todo Fixme: the --server parameter is currently not respected, as it * doesn't seem terribly easy to ask the load balancer for a particular * connection by name. + * @return DatabaseBase */ function backupDb() { $this->lb = wfGetLBFactory()->newMainLB(); diff --git a/maintenance/backupPrefetch.inc b/maintenance/backupPrefetch.inc index 93f75c65d3..0e12a1ce49 100644 --- a/maintenance/backupPrefetch.inc +++ b/maintenance/backupPrefetch.inc @@ -133,6 +133,7 @@ class BaseDump { /** * @access private + * @return string */ function nextText() { $this->skipTo( 'text' ); @@ -141,6 +142,9 @@ class BaseDump { /** * @access private + * @param $name string + * @param $parent string + * @return bool|null */ function skipTo( $name, $parent = 'page' ) { if ( $this->atEnd ) { @@ -192,6 +196,7 @@ class BaseDump { /** * @access private + * @return null */ function close() { $this->reader->close(); diff --git a/maintenance/benchmarks/benchmarkPurge.php b/maintenance/benchmarks/benchmarkPurge.php index 4ab7aa10e2..f9d345457d 100644 --- a/maintenance/benchmarks/benchmarkPurge.php +++ b/maintenance/benchmarks/benchmarkPurge.php @@ -54,6 +54,7 @@ class BenchmarkPurge extends Benchmarker { * to benchmark Squid response times. * @param $urls array A bunch of URLs to purge * @param $trials int How many times to run the test? + * @return string */ private function benchSquid( $urls, $trials = 1 ) { $start = wfTime(); @@ -70,6 +71,7 @@ class BenchmarkPurge extends Benchmarker { /** * Get an array of randomUrl()'s. * @param $length int How many urls to add to the array + * @return array */ private function randomUrlList( $length ) { $list = array(); @@ -82,6 +84,7 @@ class BenchmarkPurge extends Benchmarker { /** * Return a random URL of the wiki. Not necessarily an actual title in the * database, but at least a URL that looks like one. + * @return string */ private function randomUrl() { global $wgServer, $wgArticlePath; @@ -91,6 +94,7 @@ class BenchmarkPurge extends Benchmarker { /** * Create a random title string (not necessarily a Title object). * For use with randomUrl(). + * @return string */ private function randomTitle() { $str = ''; diff --git a/maintenance/checkSyntax.php b/maintenance/checkSyntax.php index 83f73be508..cc4e5af5e9 100644 --- a/maintenance/checkSyntax.php +++ b/maintenance/checkSyntax.php @@ -165,6 +165,8 @@ class CheckSyntax extends Maintenance { /** * Returns true if $file is of a type we can check + * @param $file string + * @return bool */ private function isSuitableFile( $file ) { $file = str_replace( '\\', '/', $file ); @@ -181,6 +183,8 @@ class CheckSyntax extends Maintenance { /** * Add given path to file list, searching it in include path if needed + * @param $path string + * @return bool */ private function addPath( $path ) { global $IP; @@ -188,8 +192,10 @@ class CheckSyntax extends Maintenance { } /** - * Add given file to file list, or, if it's a directory, add its content - */ + * Add given file to file list, or, if it's a directory, add its content + * @param $path string + * @return bool + */ private function addFileOrDir( $path ) { if ( is_dir( $path ) ) { $this->addDirectoryContent( $path ); diff --git a/maintenance/cleanupCaps.php b/maintenance/cleanupCaps.php index 2d945a52c1..d0539f5aec 100644 --- a/maintenance/cleanupCaps.php +++ b/maintenance/cleanupCaps.php @@ -88,9 +88,8 @@ class CapsCleanup extends TableCleanup { return $this->processRow( $row ); } } - } else { - $this->progress( 0 ); } + return $this->progress( 0 ); } } diff --git a/maintenance/cleanupImages.php b/maintenance/cleanupImages.php index 267061009a..81d1c85bda 100644 --- a/maintenance/cleanupImages.php +++ b/maintenance/cleanupImages.php @@ -73,8 +73,9 @@ class ImageCleanup extends TableCleanup { if ( is_null( $title ) ) { $this->output( "page $source ($cleaned) is illegal.\n" ); $safe = $this->buildSafeTitle( $cleaned ); - if ( $safe === false ) + if ( $safe === false ) { return $this->progress( 0 ); + } $this->pokeFile( $source, $safe ); return $this->progress( 1 ); } @@ -86,7 +87,7 @@ class ImageCleanup extends TableCleanup { return $this->progress( 1 ); } - $this->progress( 0 ); + return $this->progress( 0 ); } /** @@ -123,7 +124,8 @@ class ImageCleanup extends TableCleanup { $path = $this->filePath( $orig ); if ( !file_exists( $path ) ) { $this->output( "missing file: $path\n" ); - return $this->killRow( $orig ); + $this->killRow( $orig ); + return; } $db = wfGetDB( DB_MASTER ); @@ -138,7 +140,7 @@ class ImageCleanup extends TableCleanup { $version = 0; $final = $new; $conflict = ( $this->imageExists( $final, $db ) || - ( $this->pageExists( $orig, $db ) && $this->pageExists( $final, $db ) ) ); + ( $this->pageExists( $orig, $db ) && $this->pageExists( $final, $db ) ) ); while ( $conflict ) { $this->output( "Rename conflicts with '$final'...\n" ); @@ -170,7 +172,7 @@ class ImageCleanup extends TableCleanup { $dir = dirname( $finalPath ); if ( !file_exists( $dir ) ) { if ( !wfMkdirParents( $dir, null, __METHOD__ ) ) { - $this->log( "RENAME FAILED, COULD NOT CREATE $dir" ); + $this->output( "RENAME FAILED, COULD NOT CREATE $dir" ); $db->rollback(); return; } diff --git a/maintenance/cleanupUploadStash.php b/maintenance/cleanupUploadStash.php index 46bf234184..f258cab370 100644 --- a/maintenance/cleanupUploadStash.php +++ b/maintenance/cleanupUploadStash.php @@ -36,12 +36,12 @@ class UploadStashCleanup extends Maintenance { public function execute() { $repo = RepoGroup::singleton()->getLocalRepo(); - + $dbr = $repo->getSlaveDb(); // how far back should this look for files to delete? global $wgUploadStashMaxAge; - + $this->output( "Getting list of files to clean up...\n" ); $res = $dbr->select( 'uploadstash', @@ -49,10 +49,11 @@ class UploadStashCleanup extends Maintenance { 'us_timestamp < ' . $dbr->timestamp( time() - $wgUploadStashMaxAge ), __METHOD__ ); - + if( !is_object( $res ) || $res->numRows() == 0 ) { + $this->output( 'No files to cleanup!' ); // nothing to do. - return false; + return; } // finish the read before starting writes. @@ -60,13 +61,13 @@ class UploadStashCleanup extends Maintenance { foreach($res as $row) { array_push( $keys, $row->us_key ); } - + $this->output( 'Removing ' . count($keys) . " file(s)...\n" ); // this could be done some other, more direct/efficient way, but using // UploadStash's own methods means it's less likely to fall accidentally // out-of-date someday $stash = new UploadStash( $repo ); - + foreach( $keys as $key ) { $stash->getFile( $key, true ); $stash->removeFileNoAuth( $key ); @@ -75,4 +76,4 @@ class UploadStashCleanup extends Maintenance { } $maintClass = "UploadStashCleanup"; -require_once( RUN_MAINTENANCE_IF_MAIN ); \ No newline at end of file +require_once( RUN_MAINTENANCE_IF_MAIN ); diff --git a/maintenance/dumpTextPass.php b/maintenance/dumpTextPass.php index 41fd1cbcb3..0fed29fce8 100644 --- a/maintenance/dumpTextPass.php +++ b/maintenance/dumpTextPass.php @@ -66,6 +66,11 @@ class TextPassDumper extends BackupDumper { var $checkpointJustWritten = false; var $checkpointFiles = array(); + /** + * @var DatabaseBase + */ + protected $db; + function initProgress( $history ) { parent::initProgress(); $this->timeOfCheckpoint = $this->startTime; @@ -169,7 +174,8 @@ class TextPassDumper extends BackupDumper { */ function showReport() { if ( !$this->prefetch ) { - return parent::showReport(); + parent::showReport(); + return; } if ( $this->reporting ) { @@ -186,8 +192,7 @@ class TextPassDumper extends BackupDumper { $etats = wfTimestamp( TS_DB, intval( $eta ) ); if ( $this->fetchCount ) { $fetchRate = 100.0 * $this->prefetchCount / $this->fetchCount; - } - else { + } else { $fetchRate = '-'; } $pageRate = $this->pageCount / $deltaAll; @@ -201,8 +206,7 @@ class TextPassDumper extends BackupDumper { if ( $deltaPart ) { if ( $this->fetchCountLast ) { $fetchRatePart = 100.0 * $this->prefetchCountLast / $this->fetchCountLast; - } - else { + } else { $fetchRatePart = '-'; } $pageRatePart = $this->pageCountPart / $deltaPart; @@ -228,9 +232,9 @@ class TextPassDumper extends BackupDumper { function checkIfTimeExceeded() { if ( $this->maxTimeAllowed && ( $this->lastTime - $this->timeOfCheckpoint > $this->maxTimeAllowed ) ) { - return True; + return true; } - return False; + return false; } function finalOptionCheck() { @@ -286,7 +290,7 @@ class TextPassDumper extends BackupDumper { // we wrote some stuff after last checkpoint that needs renamed if (file_exists($filenameList[0])) { $newFilenames = array(); - # we might have just written the header and footer and had no + # we might have just written the header and footer and had no # pages or revisions written... perhaps they were all deleted # there's no pageID 0 so we use that. the caller is responsible # for deciding what to do with a file containing only the @@ -332,7 +336,6 @@ class TextPassDumper extends BackupDumper { } private function doGetText( $id ) { - $id = intval( $id ); $this->failures = 0; $ex = new MWException( "Graceful storage failure" ); @@ -345,9 +348,9 @@ class TextPassDumper extends BackupDumper { $this->closeSpawn(); $this->openSpawn(); } - $text = $this->getTextSpawned( $id ); + $text = $this->getTextSpawned( $id ); } else { - $text = $this->getTextDbSafe( $id ); + $text = $this->getTextDbSafe( $id ); } if ( $text === false ) { $this->failures++; @@ -359,11 +362,10 @@ class TextPassDumper extends BackupDumper { $this->failedTextRetrievals++; if ($this->failedTextRetrievals > $this->maxConsecutiveFailedTextRetrievals) { throw $ex; - } - else { + } else { // would be nice to return something better to the caller someday, // log what we know about the failure and about the revision - return(""); + return ""; } } else { $this->progress( "Error $this->failures " . @@ -373,16 +375,18 @@ class TextPassDumper extends BackupDumper { } } else { $this->failedTextRetrievals= 0; - return( $text ); + return $text; } } - + return ''; } /** * Fetch a text revision from the database, retrying in case of failure. * This may survive some transitory errors by reconnecting, but * may not survive a long-term server outage. + * + * FIXME: WTF? Why is it using a loop and then returning unconditionally? */ private function getTextDbSafe( $id ) { while ( true ) { @@ -397,6 +401,8 @@ class TextPassDumper extends BackupDumper { /** * May throw a database error if, say, the server dies during query. + * @param $id + * @return bool|string */ private function getTextDb( $id ) { global $wgContLang; @@ -584,15 +590,15 @@ class TextPassDumper extends BackupDumper { $this->egress->writeClosePage( $this->buffer ); // nasty hack, we can't just write the chardata after the // page tag, it will include leading blanks from the next line - $this->egress->sink->write("\n"); - + $this->egress->sink->write("\n"); + $this->buffer = $this->xmlwriterobj->closeStream(); $this->egress->writeCloseStream( $this->buffer ); $this->buffer = ""; $this->thisPage = ""; // this could be more than one file if we had more than one output arg - $checkpointFilenames = array(); + $filenameList = (array)$this->egress->getFilenames(); $newFilenames = array(); $firstPageID = str_pad($this->firstPageWritten,9,"0",STR_PAD_LEFT); @@ -669,10 +675,10 @@ Options: pressure on the database. (Requires the XMLReader extension) --maxtime= Write out checkpoint file after this many minutes (writing - out complete page, closing xml file properly, and opening new one + out complete page, closing xml file properly, and opening new one with header). This option requires the checkpointfile option. --checkpointfile= Use this string for checkpoint filenames, - substituting first pageid written for the first %s (required) and the + substituting first pageid written for the first %s (required) and the last pageid written for the second %s if it exists. --quiet Don't dump status reports to stderr. --report=n Report position and speed after every n pages processed. diff --git a/maintenance/fuzz-tester.php b/maintenance/fuzz-tester.php index 2348a15f45..3df3aa4451 100644 --- a/maintenance/fuzz-tester.php +++ b/maintenance/fuzz-tester.php @@ -759,14 +759,18 @@ class wikiFuzz { static private $maxparams = 10; /** - ** Returns random number between finish and start. + * Returns random number between finish and start. + * @param $finish + * @param $start int + * @return int */ static public function randnum( $finish, $start = 0 ) { return mt_rand( $start, $finish ); } /** - ** Returns a mix of random text and random wiki syntax. + * Returns a mix of random text and random wiki syntax. + * @return string */ static private function randstring() { $thestring = ""; @@ -796,18 +800,17 @@ class wikiFuzz { } /** - ** Returns either random text, or random wiki syntax, or random data from "ints", - ** or random data from "other". + * Returns either random text, or random wiki syntax, or random data from "ints", + * or random data from "other". + * @return string */ static private function makestring() { $what = wikiFuzz::randnum( 2 ); if ( $what == 0 ) { return wikiFuzz::randstring(); - } - elseif ( $what == 1 ) { + } elseif ( $what == 1 ) { return wikiFuzz::$ints[wikiFuzz::randnum( count( wikiFuzz::$ints ) - 1 )]; - } - else { + } else { return wikiFuzz::$other[wikiFuzz::randnum( count( wikiFuzz::$other ) - 1 )]; } } @@ -815,6 +818,8 @@ class wikiFuzz { /** * Returns the matched character slash-escaped as in a C string * Helper for makeTitleSafe callback + * @param $matches + * @return atring */ static private function stringEscape( $matches ) { return sprintf( "\\x%02x", ord( $matches[1] ) ); @@ -823,6 +828,8 @@ class wikiFuzz { /** ** Strips out the stuff that Mediawiki balks at in a page's title. ** Implementation copied/pasted from cleanupTable.inc & cleanupImages.php + * @param $str string + * @return string */ static public function makeTitleSafe( $str ) { $legalTitleChars = " %!\"$&'()*,\\-.\\/0-9:;=?@A-Z\\\\^_`a-z~\\x80-\\xFF"; @@ -833,6 +840,7 @@ class wikiFuzz { /** ** Returns a string of fuzz text. + * @return string */ static private function loop() { switch ( wikiFuzz::randnum( 3 ) ) { @@ -860,7 +868,8 @@ class wikiFuzz { } /** - ** Returns one of the three styles of random quote: ', ", and nothing. + * Returns one of the three styles of random quote: ', ", and nothing. + * @return string */ static private function getRandQuote() { switch ( wikiFuzz::randnum( 3 ) ) { @@ -872,6 +881,8 @@ class wikiFuzz { /** ** Returns fuzz text, with the parameter indicating approximately how many lines of text you want. + * @param $maxtypes int + * @return string */ static public function makeFuzz( $maxtypes = 2 ) { $page = ""; @@ -2174,9 +2185,10 @@ class GeSHi_Test extends pageTest { } } - /** ** selects a page test to run. + * @param $count + * @return \api|\confirmEmail|\contributionsTest|\editPageTest|\imagelistTest|\imagepageTest|\ipblocklistTest|\listusersTest|\mimeSearchTest|\newImagesTest|\pageDeletion|\pageHistoryTest|\pageProtectionForm|\prefixindexTest|\profileInfo|\recentchangesTest|\redirectTest|\searchTest|\specialAllmessagesTest|\specialAllpagesTest|\specialBlockip|\specialBlockmeTest|\specialBooksourcesTest|\specialCategoryTree|\specialChemicalsourcesTest|\specialCitePageTest|\specialExportTest|\specialFilepathPageTest|\specialImportPageTest|\specialLinksearch|\specialLockdbPageTest|\specialLogTest|\specialMovePage|\specialNewpagesPageTest|\specialRenameuserPageTest|\specialRevisionDeletePageTest|\specialUndeletePageTest|\specialUnlockdbPageTest|\specialUserrights|\successfulUserLoginTest|\thumbTest|\trackbackTest|\userLoginTest|\viewPageTest|\watchlistTest */ function selectPageTest( $count ) { @@ -2248,11 +2260,12 @@ function saveFile( $data, $name ) { file_put_contents( $name, $data ); } - /** ** Returns a test as an experimental GET-to-POST URL. ** This doesn't seem to always work though, and sometimes the output is too long ** to be a valid GET URL, so we also save in other formats. + * @param $test pageTest + * @return string */ function getAsURL( pageTest $test ) { $used_question_mark = ( strpos( $test->getPagePath(), "?" ) !== false ); @@ -2304,11 +2317,12 @@ function saveTestAsPHP( pageTest $test, $filename ) { saveFile( $str, $filename ); } - /** - ** Escapes a value so that it can be used on the command line by Curl. - ** Specifically, "<" and "@" need to be escaped if they are the first character, - ** otherwise curl interprets these as meaning that we want to insert a file. + * Escapes a value so that it can be used on the command line by Curl. + * Specifically, "<" and "@" need to be escaped if they are the first character, + * otherwise curl interprets these as meaning that we want to insert a file. + * @param $input_params array + * @return array */ function escapeForCurl( array $input_params ) { $output_params = array(); @@ -2359,18 +2373,21 @@ function saveTest( pageTest $test, $testname ) { saveTestData ( $test, $base_name . DATA_FILE ); } - // ////////////////// MEDIAWIKI OUTPUT ///////////////////////// /** - ** Asks MediaWiki for the HTML output of a test. + * Asks MediaWiki for the HTML output of a test. + * @param $test pageTest + * @return string */ function wikiTestOutput( pageTest $test ) { $ch = curl_init(); // specify the cookie, if required. - if ( $test->getCookie() ) curl_setopt( $ch, CURLOPT_COOKIE, $test->getCookie() ); + if ( $test->getCookie() ) { + curl_setopt( $ch, CURLOPT_COOKIE, $test->getCookie() ); + } curl_setopt( $ch, CURLOPT_POST, 1 ); // save form using a POST $params = escapeForCurl( $test->getParams() ); @@ -2397,6 +2414,8 @@ function wikiTestOutput( pageTest $test ) { /** * Asks the validator whether this is valid HTML, or not. + * @param $text string + * @return array */ function validateHTML( $text ) { @@ -2425,9 +2444,10 @@ function validateHTML( $text ) { return array( $valid, $result ); } - /** - ** Get tidy to check for no HTML errors in the output file (e.g. unescaped strings). + * Get tidy to check for no HTML errors in the output file (e.g. unescaped strings). + * @param $name + * @return bool */ function tidyCheckFile( $name ) { $file = DIRECTORY . "/" . $name; @@ -2446,10 +2466,10 @@ function tidyCheckFile( $name ) { } } - /** ** Returns whether or not an database error log file has changed in size since ** the last time this was run. This is used to tell if a test caused a DB error. + * @return bool */ function dbErrorLogged() { static $filesize; @@ -2477,8 +2497,12 @@ function dbErrorLogged() { // //////////////// TOP-LEVEL PROBLEM-FINDING FUNCTION //////////////////////// /** - ** takes a page test, and runs it and tests it for problems in the output. - ** Returns: False on finding a problem, or True on no problems being found. + * takes a page test, and runs it and tests it for problems in the output. + * Returns: False on finding a problem, or True on no problems being found. + * @param $test pageTest + * @param $testname + * @param $can_overwrite bool + * @return bool */ function runWikiTest( pageTest $test, &$testname, $can_overwrite = false ) { diff --git a/maintenance/generateSitemap.php b/maintenance/generateSitemap.php index b31eebd226..ab129f5452 100644 --- a/maintenance/generateSitemap.php +++ b/maintenance/generateSitemap.php @@ -188,6 +188,9 @@ class GenerateSitemap extends Maintenance { // Custom priorities if ( $wgSitemapNamespacesPriorities !== false ) { + /** + * @var $wgSitemapNamespacesPriorities array + */ foreach ( $wgSitemapNamespacesPriorities as $namespace => $priority ) { $float = floatval( $priority ); if ( $float > 1.0 ) { @@ -202,6 +205,8 @@ class GenerateSitemap extends Maintenance { /** * Create directory if it does not exist and return pathname with a trailing slash + * @param $fspath string + * @return null|string */ private static function init_path( $fspath ) { if ( !isset( $fspath ) ) { diff --git a/maintenance/importDump.php b/maintenance/importDump.php index 68fb2d888d..d92aeea081 100644 --- a/maintenance/importDump.php +++ b/maintenance/importDump.php @@ -57,7 +57,7 @@ TEXT; $this->stderr = fopen( "php://stderr", "wt" ); $this->addOption( 'report', 'Report position and speed after every n pages processed', false, true ); - $this->addOption( 'namespaces', + $this->addOption( 'namespaces', 'Import only the pages from namespaces belonging to the list of ' . 'pipe-separated namespace names or namespace indexes', false, true ); $this->addOption( 'dry-run', 'Parse dump without actually importing pages' ); @@ -154,10 +154,14 @@ TEXT; } } + /** + * @param $revision Revision + * @return bool + */ function handleUpload( $revision ) { if ( $this->uploads ) { if ( $this->skippedNamespace( $revision ) ) { - return; + return ; } $this->uploadCount++; // $this->report(); diff --git a/maintenance/jsparse.php b/maintenance/jsparse.php index ae6f1f1db0..da6798e192 100644 --- a/maintenance/jsparse.php +++ b/maintenance/jsparse.php @@ -32,7 +32,6 @@ class JSParseHelper extends Maintenance { } public function execute() { - $iterations = $this->getOption( 'i', 100 ); if ( $this->hasArg() ) { $files = $this->mArgs; } else { diff --git a/maintenance/mwdocgen.php b/maintenance/mwdocgen.php index 1e0221eb31..8279733907 100644 --- a/maintenance/mwdocgen.php +++ b/maintenance/mwdocgen.php @@ -89,6 +89,7 @@ require_once( "$mwPath/includes/GlobalFunctions.php" ); /** * Read a line from the shell * @param $prompt String + * @return string */ function readaline( $prompt = '' ) { print $prompt; @@ -151,6 +152,7 @@ function getSvnRevision( $dir ) { * @param $exclude String: Additionals path regex to exclude * @param $exclude_patterns String: Additionals path regex to exclude * (LocalSettings.php, AdminSettings.php, .svn and .git directories are always excluded) + * @return string */ function generateConfigFile( $doxygenTemplate, $outputDirectory, $stripFromPath, $currentVersion, $svnstat, $input, $exclude, $exclude_patterns ) { -- 2.20.1