diff --git a/MysqliDb.php b/MysqliDb.php index 4d91176f..d0d42189 100644 --- a/MysqliDb.php +++ b/MysqliDb.php @@ -500,8 +500,11 @@ public function getValue ($tableName, $column, $limit = 1) if (!$res) return null; - if (isset($res[0]["retval"]) && $limit == 1) - return $res[0]["retval"]; + if ($limit == 1) { + if (isset ($res[0]["retval"])) + return $res[0]["retval"]; + return null; + } $newRes = Array (); for ($i = 0; $i < $this->count; $i++)