From f1faeb038f7d4405a8d5c24a3690328279e3a5fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Sun, 2 Apr 2023 23:07:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8F=98=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Connection.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Connection.php b/Connection.php index 8495456..b695118 100644 --- a/Connection.php +++ b/Connection.php @@ -190,7 +190,9 @@ class Connection extends Component if ($restore === true) { return Context::setContext($this->cds, $this->getMasterClient()); } - if (!Db::inTransactionsActive()) return $this->getMasterClient(); + if (!Db::inTransactionsActive()) { + return $this->getMasterClient(); + } if (!Context::hasContext($this->cds)) { return Context::setContext($this->cds, $this->getMasterClient()); } else {