summaryrefslogtreecommitdiff
path: root/lib/noticelist.php
diff options
context:
space:
mode:
authorSarven Capadisli <csarven@status.net>2009-09-20 12:55:34 +0200
committerSarven Capadisli <csarven@status.net>2009-09-20 12:55:34 +0200
commit0fa2bbe581060b133fbfc48958121533aa199193 (patch)
tree8cb994bd4917023aa63ec13c62f7cd1491251e32 /lib/noticelist.php
parent4b7881c64e741d7b82f1d65bd9651148692cf1d4 (diff)
parentcf8944526ec56dd1a3522d6eced65a4d1369c321 (diff)
Merge branch '0.8.x' of git@gitorious.org:statusnet/mainline into 0.8.x
Diffstat (limited to 'lib/noticelist.php')
-rw-r--r--lib/noticelist.php14
1 files changed, 11 insertions, 3 deletions
diff --git a/lib/noticelist.php b/lib/noticelist.php
index 336457b45..d4cd3ff6e 100644
--- a/lib/noticelist.php
+++ b/lib/noticelist.php
@@ -418,9 +418,17 @@ class NoticeListItem extends Widget
function showContext()
{
- // XXX: also show context if there are replies to this notice
- if (!empty($this->notice->conversation)
- && $this->notice->conversation != $this->notice->id) {
+ $hasConversation = false;
+ if( !empty($this->notice->conversation)
+ && $this->notice->conversation != $this->notice->id){
+ $hasConversation = true;
+ }else{
+ $conversation = Notice::conversationStream($this->notice->id, 1, 1);
+ if($conversation->N > 0){
+ $hasConversation = true;
+ }
+ }
+ if ($hasConversation){
$convurl = common_local_url('conversation',
array('id' => $this->notice->conversation));
$this->out->element('a', array('href' => $convurl.'#notice-'.$this->notice->id,