From ef95c7c28479a22e41fff35a893f05eb084e1f2c Mon Sep 17 00:00:00 2001 From: Frédéric Guillot Date: Tue, 9 Sep 2014 15:15:04 +0200 Subject: Improve project api procedures --- vendor/PicoDb/Table.php | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'vendor/PicoDb') diff --git a/vendor/PicoDb/Table.php b/vendor/PicoDb/Table.php index 60a1280c..b333feb4 100644 --- a/vendor/PicoDb/Table.php +++ b/vendor/PicoDb/Table.php @@ -70,11 +70,7 @@ class Table $result = $this->db->execute($sql, $values); - if ($result !== false/* && $result->rowCount() > 0*/) { - return true; - } - - return false; + return $result !== false && $result->rowCount() > 0; } @@ -106,7 +102,9 @@ class Table $this->conditions() ); - return false !== $this->db->execute($sql, $this->values); + $result = $this->db->execute($sql, $this->values); + + return $result !== false && $result->rowCount() > 0; } -- cgit v1.2.3