PDO: switch error reporting to exceptions

This commit is contained in:
Andrew Dolgov 2018-09-03 12:30:26 +03:00
parent de1b9acba1
commit 01d22e255f
1 changed files with 2 additions and 2 deletions

View File

@ -63,7 +63,7 @@ class Db
exit(101);
}
$this->pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);
$this->pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
if (DB_TYPE == "pgsql") {