diff --git a/server/core/DB.php b/server/core/DB.php index 896aab9a..4d501d5d 100644 --- a/server/core/DB.php +++ b/server/core/DB.php @@ -134,7 +134,7 @@ function exists($table, $values, &$result = null) { $q = "SELECT * FROM $table WHERE {$where} LIMIT 1"; $result = $this->execute($q, $params); - return !is_null($result); + return count($result) > 0; } function getLastError() {