From 4876c20c9ab382c8165cf32db4a6b80bb7f6f72b Mon Sep 17 00:00:00 2001 From: Chad Horohoe Date: Thu, 5 May 2011 21:28:26 +0000 Subject: [PATCH] Fix for r87278: if we're installing with the same user we're going to use, skip creation && grants since there's no point. --- includes/installer/MysqlInstaller.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/includes/installer/MysqlInstaller.php b/includes/installer/MysqlInstaller.php index 467f0e7a60..5046df3bd0 100644 --- a/includes/installer/MysqlInstaller.php +++ b/includes/installer/MysqlInstaller.php @@ -419,6 +419,10 @@ class MysqlInstaller extends DatabaseInstaller { } public function setupUser() { + $dbUser = $this->getVar( 'wgDBuser' ); + if( $dbUser == $this->getVar( '_InstallUser' ) ) { + return Status::newGood(); + } $status = $this->getConnection(); if ( !$status->isOK() ) { return $status; @@ -428,7 +432,6 @@ class MysqlInstaller extends DatabaseInstaller { $dbName = $this->getVar( 'wgDBname' ); $this->db->selectDB( $dbName ); $server = $this->getVar( 'wgDBserver' ); - $dbUser = $this->getVar( 'wgDBuser' ); $password = $this->getVar( 'wgDBpassword' ); $grantableNames = array(); -- 2.20.1