diff --git a/src/Db/Connection.php b/src/Db/Connection.php index e654014..c04171f 100644 --- a/src/Db/Connection.php +++ b/src/Db/Connection.php @@ -29,19 +29,15 @@ class Connection $success = $statement->execute(!empty($values) ? $values : null); if (!$success) { - $statement->closeCursor(); throw new SqlException('SQL There was an error executing the request'); } $rows = $statement->fetchAll($fetchMode); if (!is_array($rows)) { - $statement->closeCursor(); throw new SqlException('PDO Unable to retrieve the result'); } - $statement->closeCursor(); - return new OdbcResultSet($rows); }