tracking another edge case

This commit is contained in:
friendica 2012-06-12 21:34:28 -07:00
parent 08af43f396
commit d955813f22

View File

@ -3393,14 +3393,16 @@ function drop_item($id,$interactive = true) {
function first_post_date($uid,$wall = false) { function first_post_date($uid,$wall = false) {
$r = q("select created from item $r = q("select id, created from item
where uid = %d and wall = %d and deleted = 0 and visible = 1 AND moderated = 0 where uid = %d and wall = %d and deleted = 0 and visible = 1 AND moderated = 0
order by created asc limit 1", order by created asc limit 1",
intval($uid), intval($uid),
intval($wall ? 1 : 0) intval($wall ? 1 : 0)
); );
if(count($r)) if(count($r)) {
logger('first_post_date: ' . $r[0]['id'] . ' ' . $r[0]['created'], LOGGER_DATA);
return substr($r[0]['created'],0,10); return substr($r[0]['created'],0,10);
}
return false; return false;
} }