From a49e9614ab5bcc3901c6d78fda2b51c34daf056f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Tue, 27 Apr 2021 18:31:23 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- System/Pool/Connection.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/System/Pool/Connection.php b/System/Pool/Connection.php index 3e66d2f9..f146be07 100644 --- a/System/Pool/Connection.php +++ b/System/Pool/Connection.php @@ -154,7 +154,7 @@ class Connection extends Pool PDO::ATTR_EMULATE_PREPARES => false, PDO::ATTR_CASE => PDO::CASE_NATURAL, PDO::ATTR_TIMEOUT => $this->timeout, - PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES ' . $config['charset'] ?? 'utf8mb4' + PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES ' . ($config['charset'] ?? 'utf8mb4') ]); $link->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); $link->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, false);