aboutsummaryrefslogtreecommitdiffstats
path: root/include/conversation.php
diff options
context:
space:
mode:
authorAlexander Kampmann <programmer@nurfuerspam.de>2012-03-09 12:17:19 +0100
committerAlexander Kampmann <programmer@nurfuerspam.de>2012-03-09 12:17:19 +0100
commitaf34cf019c5742abadab19586f3931353d8d3ff8 (patch)
treee788b55ff2bbe256d62e517d04ef25e8630313b3 /include/conversation.php
parentf84c191f8df126b95d8a41f70e785a9592018390 (diff)
parent42d622d6bfb5768205573cb6b149340d28f46886 (diff)
downloadvolse-hubzilla-af34cf019c5742abadab19586f3931353d8d3ff8.tar.gz
volse-hubzilla-af34cf019c5742abadab19586f3931353d8d3ff8.tar.bz2
volse-hubzilla-af34cf019c5742abadab19586f3931353d8d3ff8.zip
Merge branch 'master' of git://github.com/friendica/friendica
Diffstat (limited to 'include/conversation.php')
-rwxr-xr-xinclude/conversation.php33
1 files changed, 9 insertions, 24 deletions
diff --git a/include/conversation.php b/include/conversation.php
index b458923e5..526c6ea00 100755
--- a/include/conversation.php
+++ b/include/conversation.php
@@ -179,9 +179,11 @@ function localize_item(&$item){
* that are based on unique features of the calling module.
*
*/
- if(!function_exists('conversation')){
+
+if(!function_exists('conversation')) {
function conversation(&$a, $items, $mode, $update, $preview = false) {
+
require_once('bbcode.php');
$profile_owner = 0;
@@ -418,26 +420,6 @@ function conversation(&$a, $items, $mode, $update, $preview = false) {
$toplevelprivate = (($toplevelpost && $item['private']) ? true : false);
$item_writeable = (($item['writable'] || $item['self']) ? true : false);
- // DISABLED
- /*
- if($blowhard == $item['cid'] && (! $item['self']) && ($mode != 'profile') && ($mode != 'notes')) {
- $blowhard_count ++;
- if($blowhard_count == 3) {
- $o .= '<div class="icollapse-wrapper fakelink" id="icollapse-wrapper-' . $item['parent']
- . '" onclick="openClose(' . '\'icollapse-' . $item['parent'] . '\'); $(\'#icollapse-wrapper-' . $item['parent'] . '\').hide();" >'
- . t('See more posts like this') . '</div>' . '<div class="icollapse" id="icollapse-'
- . $item['parent'] . '" style="display: none;" >';
- }
- }
- else {
- $blowhard = $item['cid'];
- if($blowhard_count >= 3)
- $o .= '</div>';
- $blowhard_count = 0;
- }
- // END DISABLED
- */
-
$comments_seen = 0;
$comments_collapsed = false;
$comment_lastcollapsed = false;
@@ -445,13 +427,16 @@ function conversation(&$a, $items, $mode, $update, $preview = false) {
$threadsid++;
$threads[$threadsid]['id'] = $item['item_id'];
+ $threads[$threadsid]['private'] = $item['private'];
$threads[$threadsid]['items'] = array();
}
else {
- // prevent private email from leaking into public conversation
- if((! $toplevelpost) && (! $toplevelprivate) && ($item['private']) && ($profile_owner != local_user()))
+
+ // prevent private email reply to public conversation from leaking.
+ if($item['private'] && ! $threads[$threadsid]['private'])
continue;
+
$comments_seen ++;
$comment_lastcollapsed = false;
$comment_firstcollapsed = false;
@@ -502,7 +487,7 @@ function conversation(&$a, $items, $mode, $update, $preview = false) {
$template = $wallwall;
$commentww = 'ww';
}
- if((! $item['wall']) && (strlen($item['owner-link'])) && ($item['owner-link'] != $item['author-link'])) {
+ if((! $item['wall']) && (strlen($item['owner-link'])) && (! link_compare($item['owner-link'],$item['author-link']))) {
// Could be anybody.