From 5797dca3f58c947414504b7243755f914d4c9972 Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Mon, 27 Apr 2020 13:32:13 +0200 Subject: [inc/Database] Force strict mode with CONFIG_DEBUG --- inc/database.inc.php | 1 + 1 file changed, 1 insertion(+) diff --git a/inc/database.inc.php b/inc/database.inc.php index 7d9cbce3..eddd4faf 100644 --- a/inc/database.inc.php +++ b/inc/database.inc.php @@ -41,6 +41,7 @@ class Database Util::traceError('Connecting to the local database failed: ' . $e->getMessage()); } if (CONFIG_DEBUG) { + Database::exec("SET sql_mode='STRICT_TRANS_TABLES'"); register_shutdown_function(function() { self::examineLoggedQueries(); }); -- cgit v1.2.3-55-g7522