@@ -93,7+93,7 @@ function content_content(&$a, $update = 0) {
);
$str = '';
);
$str = '';
- if(count($r))
+ if(dbm::is_result($r))
foreach($r as $rr)
$str .= '<' . $rr['id'] . '>';
if(strlen($str))
foreach($r as $rr)
$str .= '<' . $rr['id'] . '>';
if(strlen($str))
@@ -113,7+113,7 @@ function content_content(&$a, $update = 0) {
intval($group),
intval($_SESSION['uid'])
);
intval($group),
intval($_SESSION['uid'])
);
- if(! count($r)) {
+ if(! dbm::is_result($r)) {
if($update)
killme();
notice( t('No such group') . EOL );
if($update)
killme();
notice( t('No such group') . EOL );
@@ -141,7+141,7 @@ function content_content(&$a, $update = 0) {
AND `blocked` = 0 AND `pending` = 0 LIMIT 1",
intval($cid)
);
AND `blocked` = 0 AND `pending` = 0 LIMIT 1",
intval($cid)
);
- if(count($r)) {
+ if(dbm::is_result($r)) {
$sql_extra = " AND `item`.`parent` IN ( SELECT DISTINCT(`parent`) FROM `item` WHERE 1 $sql_options AND `contact-id` = " . intval($cid) . " and deleted = 0 ) ";
}
$sql_extra = " AND `item`.`parent` IN ( SELECT DISTINCT(`parent`) FROM `item` WHERE 1 $sql_options AND `contact-id` = " . intval($cid) . " and deleted = 0 ) ";
}
@@ -259,7+259,7 @@ function content_content(&$a, $update = 0) {