PMC-1067
This commit is contained in:
2
thirdparty/pear/Console/Getopt.php
vendored
2
thirdparty/pear/Console/Getopt.php
vendored
@@ -141,7 +141,7 @@ class Console_Getopt {
|
||||
* @access private
|
||||
*
|
||||
*/
|
||||
function _parseShortOption($arg, $short_options, &$opts, &$args)
|
||||
public static function _parseShortOption($arg, $short_options, &$opts, &$args)
|
||||
{
|
||||
for ($i = 0; $i < strlen($arg); $i++) {
|
||||
$opt = $arg{$i};
|
||||
|
||||
@@ -2085,8 +2085,14 @@ class WorkspaceTools
|
||||
CLI::logging("+> Restoring database {$db->name} to $dbName\n");
|
||||
$versionBackupEngine = (isset($metadata->backupEngineVersion)) ? $metadata->backupEngineVersion : 1;
|
||||
$workspace->executeSQLScript($dbName, "$tempDirectory/{$db->name}.sql", $aParameters, $versionBackupEngine, $connection);
|
||||
$workspace->createDBUser($dbUser, ($workspace->dbGrantUserPassword != '' ? $workspace->dbGrantUserPassword : $db->pass), "localhost", $dbName, $connection);
|
||||
$workspace->createDBUser($dbUser, ($workspace->dbGrantUserPassword != '' ? $workspace->dbGrantUserPassword : $db->pass), "%", $dbName, $connection);
|
||||
// Define the password
|
||||
if (empty($workspace->dbGrantUserPassword)) {
|
||||
$bdPassword = $db->pass;
|
||||
} else {
|
||||
$bdPassword = $workspace->dbGrantUserPassword;
|
||||
}
|
||||
$workspace->createDBUser($dbUser, $bdPassword, "localhost", $dbName, $connection);
|
||||
$workspace->createDBUser($dbUser, $bdPassword, "%", $dbName, $connection);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user