From 0c9f033505be5dbc2303d8758894e57c616c6534 Mon Sep 17 00:00:00 2001 From: Friendika Date: Sun, 31 Jul 2011 16:35:53 -0700 Subject: some api enhancements --- include/conversation.php | 29 +---------------------------- 1 file changed, 1 insertion(+), 28 deletions(-) (limited to 'include/conversation.php') diff --git a/include/conversation.php b/include/conversation.php index 50032cd36..6b1f64925 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -444,7 +444,7 @@ function conversation(&$a, $items, $mode, $update) { $profile_link = ''; $normalised = normalise_link((strlen($item['author-link'])) ? $item['author-link'] : $item['url']); - if(($normalised != 'mailbox') && (x($a->contacts[$normalised]))) + if(($normalised != 'mailbox') && (x($a->contacts,$normalised))) $profile_avatar = $a->contacts[$normalised]['thumb']; else $profile_avatar = (((strlen($item['author-avatar'])) && $diff_author) ? $item['author-avatar'] : $thumb); @@ -533,33 +533,6 @@ function conversation(&$a, $items, $mode, $update) { return $o; } - -if(! function_exists('load_contact_links')) { -function load_contact_links($uid) { - - $a = get_app(); - - $ret = array(); - - if(! $uid || x($a->contacts,'empty')) - return; - - $r = q("SELECT `id`,`network`,`url`,`thumb` FROM `contact` WHERE `uid` = %d AND `self` = 0 AND `blocked` = 0 ", - intval($uid) - ); - if(count($r)) { - foreach($r as $rr){ - $url = normalise_link($rr['url']); - $ret[$url] = $rr; - } - } - else - $ret['empty'] = true; - $a->contacts = $ret; - return; -}} - - function best_link_url($item,&$sparkle) { $a = get_app(); -- cgit v1.2.3