X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fthreads.php;h=c214cf264487a6f89ddecab8248e7b81909ed5b8;hb=be35349495cdaeffa6087a51e661d4dcb83c65ca;hp=2eb05a8a360da0ff46b54a4471b0dc0cae178968;hpb=63610c7b73fcaf862adbf880d4968dd2b1678d9b;p=friendica.git diff --git a/include/threads.php b/include/threads.php index 2eb05a8a36..c214cf2644 100644 --- a/include/threads.php +++ b/include/threads.php @@ -174,7 +174,7 @@ function add_shadow_entry($itemid) { function update_thread_uri($itemuri, $uid) { $messages = q("SELECT `id` FROM `item` WHERE uri ='%s' AND uid=%d", dbesc($itemuri), intval($uid)); - if(dbm::is_result($messages)) + if (dbm::is_result($messages)) foreach ($messages as $message) update_thread($message["id"]); } @@ -267,12 +267,10 @@ function update_threads() { } 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')))",