Fix documentation (clearing w/c)
authorSam Reed <reedy@users.mediawiki.org>
Wed, 24 Aug 2011 12:47:42 +0000 (12:47 +0000)
committerSam Reed <reedy@users.mediawiki.org>
Wed, 24 Aug 2011 12:47:42 +0000 (12:47 +0000)
includes/db/Database.php
includes/db/LoadBalancer.php

index fc0f184..be06053 100644 (file)
@@ -2295,14 +2295,11 @@ abstract class DatabaseBase implements DatabaseType {
         * to collide. However if you do this, you run the risk of encountering
         * errors which wouldn't have occurred in MySQL.
         *
-        * @param $rows Can be either a single row to insert, or multiple rows,
+        * @param $table String: The table to replace the row(s) in.
+        * @param $rows array Can be either a single row to insert, or multiple rows,
         *    in the same format as for DatabaseBase::insert()
-        * @param $uniqueIndexes is an array of indexes. Each element may be either
+        * @param $uniqueIndexes array is an array of indexes. Each element may be either
         *    a field name or an array of field names
-        *
-        * @param $table String: The table to replace the row(s) in.
-        * @param $uniqueIndexes Array: An associative array of indexes
-        * @param $rows Array: Array of rows to replace
         * @param $fname String: Calling function name (use __METHOD__) for logs/profiling
         */
        function replace( $table, $uniqueIndexes, $rows, $fname = 'DatabaseBase::replace' ) {
index 171ca2e..506ceb9 100644 (file)
@@ -117,7 +117,7 @@ class LoadBalancer {
                        return false;
                }
                $max = mt_getrandmax();
-               $rand = mt_rand(0, $max) / $max * $sum;
+               $rand = mt_rand( 0, $max ) / $max * $sum;
 
                $sum = 0;
                foreach ( $weights as $i => $w ) {