]> git.wh0rd.org Git - tt-rss.git/commitdiff
PDO: switch error reporting to exceptions
authorAndrew Dolgov <noreply@fakecake.org>
Mon, 3 Sep 2018 09:30:26 +0000 (12:30 +0300)
committerAndrew Dolgov <noreply@fakecake.org>
Mon, 3 Sep 2018 09:30:26 +0000 (12:30 +0300)
classes/db.php

index 96a8882751078adb63d72e7ac623d9e2a87ea741..e9d9e8417bb7fbf681f2933570f23b3ad245c564 100644 (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") {
 
@@ -102,4 +102,4 @@ class Db
 
                return self::$instance->pdo;
        }
-}
\ No newline at end of file
+}