]> git.mxchange.org Git - friendica.git/blobdiff - mod/dirfind.php
Merge pull request #5862 from nupplaphil/rename_App_Methods
[friendica.git] / mod / dirfind.php
index f4ddba45d4be253efade4b848c6b1b2048d43c19..5fe9ae13af32adacf7b8d0e8c34fb25b10fcf1bf 100644 (file)
@@ -44,7 +44,7 @@ function dirfind_content(App $a, $prefix = "") {
 
        $local = Config::get('system','poco_local_search');
 
-       $search = $prefix.notags(trim($_REQUEST['search']));
+       $search = $prefix.notags(trim(defaults($_REQUEST, 'search', '')));
 
        $header = '';
 
@@ -54,7 +54,7 @@ function dirfind_content(App $a, $prefix = "") {
                if ((valid_email($search) && Network::isEmailDomainValid($search)) ||
                        (substr(normalise_link($search), 0, 7) == "http://")) {
                        $user_data = Probe::uri($search);
-                       $discover_user = (in_array($user_data["network"], [Protocol::DFRN, Protocol::OSTATUS, Protocol::DIASPORA]));
+                       $discover_user = (in_array($user_data["network"], [Protocol::ACTIVITYPUB, Protocol::DFRN, Protocol::OSTATUS, Protocol::DIASPORA]));
                }
        }
 
@@ -188,8 +188,8 @@ function dirfind_content(App $a, $prefix = "") {
                }
 
                if ($j->total) {
-                       $a->set_pager_total($j->total);
-                       $a->set_pager_itemspage($j->items_page);
+                       $a->setPagerTotal($j->total);
+                       $a->setPagerItemsPage($j->items_page);
                }
 
                if (!empty($j->results)) {