]> git.mxchange.org Git - friendica.git/blobdiff - include/conversation.php
Merge branch 'master' of github.com:annando/friendica
[friendica.git] / include / conversation.php
index e48a8e6d603acbc279b892f8653f028575c250a4..dc574ddff8e899a0caa0f494d1e46dff0324565c 100644 (file)
@@ -174,6 +174,7 @@ function localize_item(&$item){
                }
        }
 
+
 }
 
 /**
@@ -278,6 +279,9 @@ function conversation(&$a, $items, $mode, $update, $preview = false) {
                                else
                                        $nickname = $a->user['nickname'];
                                
+                               // prevent private email from leaking.
+                               if($item['network'] === NETWORK_MAIL && local_user() != $item['uid'])
+                                               continue;
                        
                                $profile_name   = ((strlen($item['author-name']))   ? $item['author-name']   : $item['name']);
                                if($item['author-link'] && (! $item['author-name']))
@@ -447,8 +451,8 @@ function conversation(&$a, $items, $mode, $update, $preview = false) {
                                else {
 
                                        // prevent private email reply to public conversation from leaking.
-                                       if($item['private'] && ! $threads[$threadsid]['private'])
-                                               continue;
+                                       if($item['network'] === NETWORK_MAIL && local_user() != $item['uid'])
+                                                       continue;
 
                                        $comments_seen ++;
                                        $comment_lastcollapsed  = false;