fix some of the group poll issues. Remaining: don't Announce answers, group owner unable to vote currently

This commit is contained in:
nobody 2021-09-28 18:28:12 -07:00
parent 0ed7cd4afc
commit 3a9d47673d
3 changed files with 8 additions and 3 deletions

View file

@ -452,6 +452,10 @@ class Notifier {
$upstream = false;
if ($parent_item && $parent_item['item_private'] !== $target_item['item_private']) {
logger('parent_item: ' . $parent_item['id'] . ' item_private: ' . $parent_item['item_private']);
logger('target_item: ' . $target_item['id'] . ' item_private: ' . $target_item['item_private']);
logger('conversation privacy mismatch - downstream delivery prevented');
return;
}

View file

@ -91,8 +91,8 @@ class Vote extends Controller {
$item['title'] = $res;
$item['author_xchan'] = $channel['channel_hash'];
$item['owner_xchan'] = $fetch[0]['author_xchan'];
$item['allow_cid'] = '<' . $fetch[0]['author_xchan'] . '>';
$item['item_private'] = 1;
// $item['allow_cid'] = '<' . $fetch[0]['author_xchan'] . '>';
// $item['item_private'] = 1;
// These two are placeholder values that will be reset after
// we encode the item

View file

@ -3203,6 +3203,8 @@ function start_delivery_chain($channel, $item, $item_id, $parent, $group = false
}
$arr['obj']['content'] = bbcode($bb, [ 'export' => true ]);
$arr['obj']['source']['content'] = $bb;
$arr['obj']['id'] = $arr['mid'];
if (! array_path_exists('obj/source/mediaType',$arr)) {
$arr['obj']['source']['mediaType'] = 'text/bbcode';
}
@ -3230,7 +3232,6 @@ function start_delivery_chain($channel, $item, $item_id, $parent, $group = false
$arr['replyto'] = z_root() . '/channel/' . $channel['channel_address'];
if ($arr['id']) {
$post = item_store_update($arr);
}