aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMario Vavti <mario@mariovavti.com>2023-08-21 10:45:12 +0200
committerMario <mario@mariovavti.com>2023-08-27 20:01:01 +0200
commit5e0c392287e622eef4844f73130623092433dfd0 (patch)
treebcc3b66310be60e2b7cbf39d90264bbb6c57f349
parent05ff94941c4aaeb0c9d1eeda64d5af0071ea64b9 (diff)
downloadvolse-hubzilla-5e0c392287e622eef4844f73130623092433dfd0.tar.gz
volse-hubzilla-5e0c392287e622eef4844f73130623092433dfd0.tar.bz2
volse-hubzilla-5e0c392287e622eef4844f73130623092433dfd0.zip
test refactor the previous commit
(cherry picked from commit 0a3094fc9a708c4e83d6dd91250ac2105e21b03f)
-rw-r--r--Zotlabs/Lib/Activity.php11
1 files changed, 7 insertions, 4 deletions
diff --git a/Zotlabs/Lib/Activity.php b/Zotlabs/Lib/Activity.php
index 8066b1857..cbf3dd85d 100644
--- a/Zotlabs/Lib/Activity.php
+++ b/Zotlabs/Lib/Activity.php
@@ -2363,6 +2363,9 @@ class Activity {
$s['mid'] = $act->id;
$s['uuid'] = ((!empty($act->data['diaspora:guid'])) ? $act->data['diaspora:guid'] : uuid_from_url($s['mid']));
+ $s['parent_mid'] = $act->objprop('id') ?: $act->obj;
+
+/*
if ($act->objprop('inReplyTo')) {
$s['parent_mid'] = $act->objprop('inReplyTo');
}
@@ -2373,7 +2376,7 @@ class Activity {
logger('response activity without parent_mid or thr_parent');
return;
}
-
+*/
// over-ride the object timestamp with the activity
if (isset($act->data['published'])) {
@@ -3161,7 +3164,7 @@ class Activity {
return;
}
-/*
+
if ($parent[0]['parent_mid'] !== $item['parent_mid']) {
$item['thr_parent'] = $item['parent_mid'];
}
@@ -3169,7 +3172,7 @@ class Activity {
$item['thr_parent'] = $parent[0]['parent_mid'];
}
$item['parent_mid'] = $parent[0]['parent_mid'];
-*/
+
/*
*
@@ -3288,7 +3291,7 @@ class Activity {
$current_item = $item;
while ($current_item['parent_mid'] !== $current_item['mid']) {
- $n = self::fetch(((in_array($current_item['verb'], [ACTIVITY_LIKE, ACTIVITY_DISLIKE])) ? $current_item['thr_parent'] : $current_item['parent_mid']), $channel);
+ $n = self::fetch($current_item['parent_mid'], $channel);
if (!$n) {
break;