diff options
author | friendica <info@friendica.com> | 2014-09-04 18:52:37 -0700 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-09-04 18:52:37 -0700 |
commit | 955567fe5f517ec90623a4bf7f652fe2e02e1271 (patch) | |
tree | 164c6df964e41c7f250e6e5613f02bba17729bfb /include | |
parent | e426f48a26542a169fc8e574491d5eaaa0258476 (diff) | |
download | volse-hubzilla-955567fe5f517ec90623a4bf7f652fe2e02e1271.tar.gz volse-hubzilla-955567fe5f517ec90623a4bf7f652fe2e02e1271.tar.bz2 volse-hubzilla-955567fe5f517ec90623a4bf7f652fe2e02e1271.zip |
unset item_nocomment when starting a new delivery chain
Diffstat (limited to 'include')
-rwxr-xr-x | include/items.php | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/include/items.php b/include/items.php index 297a62fb4..c96a5e4ed 100755 --- a/include/items.php +++ b/include/items.php @@ -2844,7 +2844,6 @@ function tgroup_check($uid,$item) { function start_delivery_chain($channel,$item,$item_id,$parent) { - // Change this copy of the post to a forum head message and deliver to all the tgroup members // also reset all the privacy bits to the forum default permissions @@ -2858,6 +2857,11 @@ function start_delivery_chain($channel,$item,$item_id,$parent) { $flag_bits = $item['item_flags'] | ITEM_WALL|ITEM_ORIGIN; + // unset the nocomment bit if it's there. + + if($flag_bits & ITEM_NOCOMMENT) + $flag_bits = $flag_bits ^ ITEM_NOCOMMENT; + // maintain the original source, which will be the original item owner and was stored in source_xchan // when we created the delivery fork @@ -2944,6 +2948,7 @@ function check_item_source($uid,$item) { dbesc(($item['source_xchan']) ? $item['source_xchan'] : $item['owner_xchan']) ); + if(! $r) return false; @@ -2951,10 +2956,12 @@ function check_item_source($uid,$item) { intval($uid), dbesc($item['owner_xchan']) ); + if(! $x) return false; + if(! ($x[0]['abook_their_perms'] & PERMS_A_REPUBLISH)) return false; |