diff options
author | Christoph Wurst <ChristophWurst@users.noreply.github.com> | 2021-01-08 14:58:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-08 14:58:43 +0100 |
commit | 81302f78e5cea60dc9064be8ed979d523ff84e18 (patch) | |
tree | 76e8d025c3003e718cf5e04105b782ba8aaa4891 /lib/private/DB/ReconnectWrapper.php | |
parent | aeb32e1bc8f50d641e093589cc2f8c90da166768 (diff) | |
parent | 250f76a59cfc865e2a6bd36b690abeed3b529490 (diff) | |
download | nextcloud-server-81302f78e5cea60dc9064be8ed979d523ff84e18.tar.gz nextcloud-server-81302f78e5cea60dc9064be8ed979d523ff84e18.zip |
Merge pull request #24948 from nextcloud/dependabot/composer/doctrine/dbal-3.0.0
Bump doctrine/dbal from 2.12.0 to 3.0.0
Diffstat (limited to 'lib/private/DB/ReconnectWrapper.php')
-rw-r--r-- | lib/private/DB/ReconnectWrapper.php | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/private/DB/ReconnectWrapper.php b/lib/private/DB/ReconnectWrapper.php index 9599d6b0fe6..a0170152862 100644 --- a/lib/private/DB/ReconnectWrapper.php +++ b/lib/private/DB/ReconnectWrapper.php @@ -44,12 +44,12 @@ class ReconnectWrapper extends \Doctrine\DBAL\Connection { if ($this->lastConnectionCheck > $checkTime || $this->isTransactionActive()) { return parent::connect(); - } else { - $this->lastConnectionCheck = $now; - if (!$this->ping()) { - $this->close(); - } - return parent::connect(); } + + $this->lastConnectionCheck = $now; + if (!$this->isConnected()) { + $this->close(); + } + return parent::connect(); } } |