From 6f3b46217ed09c7abec4f0c193219468853ad35f Mon Sep 17 00:00:00 2001 From: Michael Date: Tue, 28 Apr 2020 19:36:10 +0000 Subject: [PATCH] Fix for "Undefined index: profile_url" --- src/Core/Search.php | 2 +- src/Module/Directory.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Core/Search.php b/src/Core/Search.php index 8415723742..4742ac5993 100644 --- a/src/Core/Search.php +++ b/src/Core/Search.php @@ -142,7 +142,7 @@ class Search $profiles = $results['profiles'] ?? []; foreach ($profiles as $profile) { - $profile_url = $profile['profile_url'] ?? ''; + $profile_url = $profile['url'] ?? ''; $contactDetails = Contact::getDetailsByURL($profile_url, local_user()); $result = new ContactResult( diff --git a/src/Module/Directory.php b/src/Module/Directory.php index 0709aa3974..3d03f10711 100644 --- a/src/Module/Directory.php +++ b/src/Module/Directory.php @@ -120,9 +120,9 @@ class Directory extends BaseModule */ public static function formatEntry(array $contact, $photo_size = 'photo') { - $itemurl = (($contact['addr'] != "") ? $contact['addr'] : $contact['profile_url']); + $itemurl = (($contact['addr'] != "") ? $contact['addr'] : $contact['url']); - $profile_link = $contact['profile_url']; + $profile_link = $contact['url']; $about = (($contact['about']) ? $contact['about'] . '
' : ''); -- 2.39.5