From e8c39ff49fdb12461b375db8ab6591ced646f613 Mon Sep 17 00:00:00 2001 From: Mike Macgirvin Date: Thu, 9 Sep 2010 05:25:01 -0700 Subject: found the missing comment box bug --- mod/item.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'mod/item.php') diff --git a/mod/item.php b/mod/item.php index 08f65dca1..20a2488c5 100644 --- a/mod/item.php +++ b/mod/item.php @@ -287,8 +287,9 @@ function item_content(&$a) { intval($item['uid']) ); // who is the last child now? - $r = q("SELECT `id` FROM `item` WHERE `parent-uri` = '%s' AND `type` != 'activity' AND `deleted` = 0 ORDER BY `edited` DESC LIMIT 1", - dbesc($item['parent-uri']) + $r = q("SELECT `id` FROM `item` WHERE `parent-uri` = '%s' AND `type` != 'activity' AND `deleted` = 0 AND `uid` = %d ORDER BY `edited` DESC LIMIT 1", + dbesc($item['parent-uri']), + intval($item['uid']) ); if(count($r)) { q("UPDATE `item` SET `last-child` = 1 WHERE `id` = %d LIMIT 1", -- cgit v1.2.3