summaryrefslogtreecommitdiff
path: root/maintenance/upgrade1_5.php
diff options
context:
space:
mode:
Diffstat (limited to 'maintenance/upgrade1_5.php')
-rw-r--r--maintenance/upgrade1_5.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/maintenance/upgrade1_5.php b/maintenance/upgrade1_5.php
index 1577c237..1e268de3 100644
--- a/maintenance/upgrade1_5.php
+++ b/maintenance/upgrade1_5.php
@@ -28,7 +28,7 @@
* @ingroup Maintenance
*/
-require_once( dirname( __FILE__ ) . '/Maintenance.php' );
+require_once( __DIR__ . '/Maintenance.php' );
define( 'MW_UPGRADE_COPY', false );
define( 'MW_UPGRADE_ENCODE', true );
@@ -116,7 +116,7 @@ class FiveUpgrade extends Maintenance {
/**
* Open a connection to the master server with the admin rights.
- * @return Database
+ * @return DatabaseBase
* @access private
*/
function newConnection() {
@@ -141,7 +141,7 @@ class FiveUpgrade extends Maintenance {
* Open a second connection to the master server, with buffering off.
* This will let us stream large datasets in and write in chunks on the
* other end.
- * @return Database
+ * @return DatabaseBase
* @access private
*/
function streamConnection() {
@@ -252,7 +252,7 @@ class FiveUpgrade extends Maintenance {
$this->chunkSize = $chunksize;
$this->chunkFinal = $final;
$this->chunkCount = 0;
- $this->chunkStartTime = wfTime();
+ $this->chunkStartTime = microtime( true );
$this->chunkOptions = array( 'IGNORE' );
$this->chunkTable = $table;
$this->chunkFunction = $fname;
@@ -273,7 +273,7 @@ class FiveUpgrade extends Maintenance {
$this->insertChunk( $chunk );
$this->chunkCount += count( $chunk );
- $now = wfTime();
+ $now = microtime( true );
$delta = $now - $this->chunkStartTime;
$rate = $this->chunkCount / $delta;
@@ -342,7 +342,7 @@ class FiveUpgrade extends Maintenance {
* MW_UPGRADE_COPY - straight copy
* MW_UPGRADE_ENCODE - for old Latin1 wikis, conv to UTF-8
* MW_UPGRADE_NULL - just put NULL
- * @param callable $callback An optional callback to modify the data
+ * @param $callback callback An optional callback to modify the data
* or perform other processing. Func should be
* ( object $row, array $copy ) and return $copy
* @access private