diff options
-rw-r--r-- | Zotlabs/Lib/Activity.php | 4 | ||||
-rw-r--r-- | Zotlabs/Lib/Libzot.php | 1 | ||||
-rw-r--r-- | Zotlabs/Module/Activity.php | 4 |
3 files changed, 5 insertions, 4 deletions
diff --git a/Zotlabs/Lib/Activity.php b/Zotlabs/Lib/Activity.php index d1a1a1385..631606c46 100644 --- a/Zotlabs/Lib/Activity.php +++ b/Zotlabs/Lib/Activity.php @@ -2020,12 +2020,12 @@ class Activity { $s['expires'] = datetime_convert('UTC','UTC',$act->obj['expires']); } - if(in_array($act->type, [ 'Like', 'Dislike', 'Flag', 'Block', 'Announce', 'Accept', 'Reject', 'TentativeAccept', 'emojiReaction' ])) { + if(in_array($act->type, [ 'Like', 'Dislike', 'Flag', 'Block', 'Announce', 'Accept', 'Reject', 'TentativeAccept', 'emojiReaction', 'Undo', 'Delete' ])) { $response_activity = true; $s['mid'] = $act->id; - $s['parent_mid'] = $act->obj['id']; + $s['parent_mid'] = $act->parent_id; //$act->obj['id']; $s['uuid'] = $act->data['diaspora:guid']; // over-ride the object timestamp with the activity diff --git a/Zotlabs/Lib/Libzot.php b/Zotlabs/Lib/Libzot.php index d7285ca12..ab322ca86 100644 --- a/Zotlabs/Lib/Libzot.php +++ b/Zotlabs/Lib/Libzot.php @@ -1141,6 +1141,7 @@ class Libzot { } logger($AS->debug(),LOGGER_DATA); + } diff --git a/Zotlabs/Module/Activity.php b/Zotlabs/Module/Activity.php index 8f4593db3..b75f0b245 100644 --- a/Zotlabs/Module/Activity.php +++ b/Zotlabs/Module/Activity.php @@ -19,6 +19,7 @@ class Activity extends Controller { function init() { if (Libzot::is_zot_request()) { + $item_id = argv(1); if (! $item_id) http_status_exit(404, 'Not found'); @@ -200,7 +201,6 @@ class Activity extends Controller { and item.item_delayed = 0 and item.item_blocked = 0 "; $sigdata = HTTPSig::verify(EMPTY_STR); - if ($sigdata['portable_id'] && $sigdata['header_valid']) { $portable_id = $sigdata['portable_id']; if (! check_channelallowed($portable_id)) { @@ -221,6 +221,7 @@ class Activity extends Controller { else { $sql_extra = item_permissions_sql(0); } + $r = q("select * from item where uuid = '%s' $item_normal $sql_extra limit 1", dbesc($item_id) ); @@ -246,7 +247,6 @@ class Activity extends Controller { z_root() . ZOT_APSCHEMA_REV ]], ZlibActivity::encode_activity($items[0],true)); - $headers = []; $headers['Content-Type'] = 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"' ; $x['signature'] = LDSignatures::sign($x,$channel); |