[-] CORE : Fix warning when result from query is not a ressource

This commit is contained in:
gRoussac
2013-02-13 19:53:48 +01:00
parent 7402d7b93d
commit 876b4c09bc
+6 -1
View File
@@ -68,7 +68,12 @@ class MySQLCore extends Db
*/
public function nextRow($result = false)
{
return mysql_fetch_assoc($result ? $result : $this->result);
$return = false;
if(is_resource($result) && $result)
$return = mysql_fetch_assoc($result);
elseif(is_resource($this->_result) && $this->_result)
$return = mysql_fetch_assoc($this->_result);
return $return;
}
/**