aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Vote.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2020-02-10 12:25:11 +0100
committerMario <mario@mariovavti.com>2020-02-10 12:25:11 +0100
commit50dbe1e62d8da44a710f1eb0f7e9d9eaf88c4084 (patch)
treea5a7646e1401b2c943d426f1198c3834f62baee6 /Zotlabs/Module/Vote.php
parent33be244d8a4ab62d52f7715b5f95ed293be79504 (diff)
parentbbcb237f5b996e94af37611152105b2e965ea493 (diff)
downloadvolse-hubzilla-50dbe1e62d8da44a710f1eb0f7e9d9eaf88c4084.tar.gz
volse-hubzilla-50dbe1e62d8da44a710f1eb0f7e9d9eaf88c4084.tar.bz2
volse-hubzilla-50dbe1e62d8da44a710f1eb0f7e9d9eaf88c4084.zip
Merge branch 'dev' into 'dev'
poll updates See merge request hubzilla/core!1828
Diffstat (limited to 'Zotlabs/Module/Vote.php')
-rw-r--r--Zotlabs/Module/Vote.php18
1 files changed, 14 insertions, 4 deletions
diff --git a/Zotlabs/Module/Vote.php b/Zotlabs/Module/Vote.php
index 52d6a4bea..2c31d84dc 100644
--- a/Zotlabs/Module/Vote.php
+++ b/Zotlabs/Module/Vote.php
@@ -88,15 +88,25 @@ class Vote extends Controller {
$item['parent_mid'] = $fetch[0]['mid'];
$item['uuid'] = new_uuid();
$item['mid'] = z_root() . '/item/' . $item['uuid'];
- $item['verb'] = 'Answer';
+ $item['verb'] = 'Create';
$item['title'] = $res;
$item['author_xchan'] = $channel['channel_hash'];
$item['owner_xchan'] = $fetch[0]['author_xchan'];
- $item['obj'] = $obj;
- $item['obj_type'] = 'Question';
+ $item['obj_type'] = 'Note';
+ $item['author'] = channelx_by_n($channel['channel_id']);
+
+ $item['obj'] = Activity::encode_item($item,true);
+
+ // now reset the placeholders
+
+ $item['obj_type'] = 'Answer';
+ unset($item['author']);
+
+
+ $x = item_store($item);
+
- $x = item_store($item);
retain_item($fetch[0]['id']);