]> git.mxchange.org Git - friendica.git/commitdiff
Hopefully fix some tests
authorMichael <heluecht@pirati.ca>
Sun, 21 Nov 2021 00:44:26 +0000 (00:44 +0000)
committerMichael <heluecht@pirati.ca>
Sun, 21 Nov 2021 00:44:26 +0000 (00:44 +0000)
include/api.php

index d097c8d669d548d5be6b3d2f130fec160aa69519..ef0e0bfbd0b2093116bafe7c7232a3afaf8312b9 100644 (file)
@@ -3725,7 +3725,7 @@ function api_in_reply_to($item)
        $in_reply_to['user_id_str'] = null;
        $in_reply_to['screen_name'] = null;
 
-       if (($item['thr-parent'] != $item['uri']) && ($item['gravity'] != GRAVITY_PARENT)) {
+       if (!empty($item['thr-parent']) && ($item['thr-parent'] != $item['uri']) && ($item['gravity'] != GRAVITY_PARENT)) {
                $parent = Post::selectFirst(['id'], ['uid' => $item['uid'], 'uri' => $item['thr-parent']]);
                if (DBA::isResult($parent)) {
                        $in_reply_to['status_id'] = intval($parent['id']);