]> git.mxchange.org Git - friendica.git/blobdiff - mod/dirfind.php
Fix profile wrong DISTINCT + ORDER BY
[friendica.git] / mod / dirfind.php
index 0e5f8a90d1b3bebe020b3f61375aca00b05655d1..c5844d13dfa742689c0e202a7a9cd92a9772fd68 100644 (file)
@@ -73,9 +73,9 @@ function dirfind_content(App $a, $prefix = "") {
                        $j->results[] = $objresult;
 
                        // Add the contact to the global contacts if it isn't already in our system
-                       if (($contact["cid"] == 0) AND ($contact["zid"] == 0) AND ($contact["gid"] == 0))
-                               poco_check($user_data["url"], $user_data["name"], $user_data["network"], $user_data["photo"],
-                                       "", "", "", "", "", datetime_convert(), 0);
+                       if (($contact["cid"] == 0) AND ($contact["zid"] == 0) AND ($contact["gid"] == 0)) {
+                               update_gcontact($user_data);
+                       }
                } elseif ($local) {
 
                        if ($community)
@@ -166,9 +166,8 @@ function dirfind_content(App $a, $prefix = "") {
 
                        $p = (($a->pager['page'] != 1) ? '&p=' . $a->pager['page'] : '');
 
-                       if (strlen(get_config('system','directory'))) {
+                       if(strlen(get_config('system','directory')))
                                $x = fetch_url(get_server().'/lsearch?f=' . $p .  '&search=' . urlencode($search));
-                       }
 
                        $j = json_decode($x);
                }