mirror of
https://github.com/grocy/grocy.git
synced 2025-08-20 12:20:22 +00:00
Form validation and barcode input handling improvements
This commit is contained in:
@@ -72,7 +72,11 @@ class GrocyDbMigrator
|
||||
{
|
||||
if ($pdo->query("SELECT COUNT(*) FROM migrations WHERE migration = $migrationId")->fetchColumn() == 0)
|
||||
{
|
||||
$pdo->exec(utf8_encode($sql));
|
||||
if ($pdo->exec(utf8_encode($sql)) === false)
|
||||
{
|
||||
throw new Exception($pdo->errorInfo());
|
||||
}
|
||||
|
||||
$pdo->exec('INSERT INTO migrations (migration) VALUES (' . $migrationId . ')');
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user