diff --git a/src/Connection.php b/src/Connection.php index ef77ac1..bfc3f70 100644 --- a/src/Connection.php +++ b/src/Connection.php @@ -191,7 +191,7 @@ public function disconnect() public function ping($reconnect = true) { try { - $this->exec('SELECT 1'); + $this->query('SELECT 1')->closeCursor(); } catch (Exception $e) { if (! $reconnect) { return false;