"need to use verbose parameter for restore too"

This commit is contained in:
Ralf Becker 2008-11-23 13:09:16 +00:00
parent 6f442ea296
commit d379065824

View File

@ -72,12 +72,23 @@ class setup_cmd_install extends setup_cmd
if (!is_resource($f = $db_backup->fopen_backup($this->backup,true))) if (!is_resource($f = $db_backup->fopen_backup($this->backup,true)))
{ {
throw new egw_exception_wrong_userinput(lang('Restore failed'),31); throw new egw_exception_wrong_userinput(lang('Restore failed').' ('.$f.')',31);
}
if ($this->verbose)
{
echo lang('Restore started, this might take a few minutes ...')."\n";
}
else
{
ob_start(); // restore echos the table structure
} }
//echo lang('Restore started, this might take a few minutes ...')."\n";
$db_backup->restore($f,$this->charset); $db_backup->restore($f,$this->charset);
fclose($f); fclose($f);
if (!$this->verbose)
{
ob_end_clean();
}
return lang('Restore finished'); return lang('Restore finished');
} }
// regular (new) install // regular (new) install