Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Neto committed Jul 28, 2024
1 parent 1ba3982 commit 623829f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions install/mysqlRestore.php
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,12 @@ function executeFile($filename) {
foreach ($tables as $table) {
$dropTableCommand = 'DROP TABLE IF EXISTS `' . $table . '`;';
echo "Executing: $dropTableCommand\n"; // Imprimir o comando SQL
if (!$global['mysqli']->query($dropTableCommand)) {
echo ('sqlDAL::executeFile ' . $filename . ' Error performing query \'<strong>' . $dropTableCommand . '\': ' . $global['mysqli']->error . '<br /><br />');
try {
if (!$global['mysqli']->query($dropTableCommand)) {
echo ('sqlDAL::executeFile ' . $filename . ' Error performing query \'<strong>' . $dropTableCommand . '\': ' . $global['mysqli']->error . '<br /><br />');
}
} catch (\Throwable $th) {
echo 'Error: '.$th->getMessage().PHP_EOL;
}
}

Expand Down

0 comments on commit 623829f

Please sign in to comment.