X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fthreads.php;h=c214cf264487a6f89ddecab8248e7b81909ed5b8;hb=e24c3a5b826d2357e40a173d9e7b66048dab5b37;hp=0320eaa018e98b28a04179f79aae2b020bbd68da;hpb=f192767d7ad1eace0a9f5e33ba8d2625782ad562;p=friendica.git diff --git a/include/threads.php b/include/threads.php index 0320eaa018..c214cf2644 100644 --- a/include/threads.php +++ b/include/threads.php @@ -1,7 +1,9 @@ qfetch()) + while ($message = $db->qfetch()) { add_thread($message["id"]); + add_shadow_thread($message["id"]); + } $db->qclose(); } function update_threads_mention() { - $a = get_app(); - $users = q("SELECT `uid`, `nickname` FROM `user` ORDER BY `uid`"); foreach ($users AS $user) { - $self = normalise_link($a->get_baseurl() . '/profile/' . $user['nickname']); + $self = normalise_link(App::get_baseurl() . '/profile/' . $user['nickname']); $selfhttps = str_replace("http://", "https://", $self); $parents = q("SELECT DISTINCT(`parent`) FROM `item` WHERE `uid` = %d AND ((`owner-link` IN ('%s', '%s')) OR (`author-link` IN ('%s', '%s')))", @@ -225,7 +293,7 @@ function update_shadow_copy() { logger("fetched messages: ".count($messages)); while ($message = $db->qfetch()) - add_thread($message["iid"], true); + add_shadow_thread($message["iid"]); $db->qclose(); }