diff options
author | redmatrix <redmatrix@redmatrix.me> | 2015-08-12 22:48:08 -0700 |
---|---|---|
committer | redmatrix <redmatrix@redmatrix.me> | 2015-08-12 22:48:08 -0700 |
commit | ef73880459e43cd976bfa4fd11f8a595a0b81d77 (patch) | |
tree | d23f780c2786854f0634d2435f9064e8deeb5195 | |
parent | f88dc84091844a4a36dca4da6ce6f1e8bc57c470 (diff) | |
download | volse-hubzilla-ef73880459e43cd976bfa4fd11f8a595a0b81d77.tar.gz volse-hubzilla-ef73880459e43cd976bfa4fd11f8a595a0b81d77.tar.bz2 volse-hubzilla-ef73880459e43cd976bfa4fd11f8a595a0b81d77.zip |
reverting 36b5f6ac
-rw-r--r-- | include/zot.php | 29 |
1 files changed, 18 insertions, 11 deletions
diff --git a/include/zot.php b/include/zot.php index bb1ccc46a..6d04bc024 100644 --- a/include/zot.php +++ b/include/zot.php @@ -1537,17 +1537,24 @@ function process_delivery($sender, $arr, $deliveries, $relay, $public = false, $ $tag_delivery = tgroup_check($channel['channel_id'],$arr); - if ($arr['mid'] == $arr['parent_mid']){ - $perm = 'send_stream'; - } - else{ - $r = q("select item_owner from item where item.mid == '%s' limit 1", - dbesc($arr['parent_mid'])); - if($channel['channel_hash'] == $r[0]['item_owner']) - $perm = 'post_comments'; - else - $perm = 'send_stream'; - } + + $perm = (($arr['mid'] == $arr['parent_mid']) ? 'send_stream' : 'post_comments'); + +// checkin 36b5f6ac - multiple issues, not yet ready for prime time +// currently this is mostly fixed except for what to do if the post is in a second delivery chain +// if ($arr['mid'] == $arr['parent_mid']){ +// $perm = 'send_stream'; +// } +// else{ +// $perm = 'post_comments'; +// +// $r = q("select owner_xchan from item where item.mid = '%s' and uid = %d limit 1", +// dbesc($arr['parent_mid']), +// intval($channel['channel_id']) +// ); +// if(($r) && $channel['channel_hash'] !== $r[0]['owner_xchan']) +// $perm = 'send_stream'; +// } // This is our own post, possibly coming from a channel clone |