From 32a8f5003fb8d1b13443eafa7033e6d7406af885 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Sat, 11 Jul 2020 09:18:18 -0400 Subject: [PATCH] Add provision for result containing only connector profiles in Contact::getDetailsByURL --- src/Model/Contact.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Model/Contact.php b/src/Model/Contact.php index b11919b528..46104aaeae 100644 --- a/src/Model/Contact.php +++ b/src/Model/Contact.php @@ -1077,7 +1077,6 @@ class Contact } if (DBA::isResult($r)) { - $authoritativeResult = true; // If there is more than one entry we filter out the connector networks if (count($r) > 1) { foreach ($r as $id => $result) { @@ -1088,7 +1087,10 @@ class Contact } $profile = array_shift($r); + } + if (!empty($profile)) { + $authoritativeResult = true; // "bd" always contains the upcoming birthday of a contact. // "birthday" might contain the birthday including the year of birth. if ($profile["birthday"] > DBA::NULL_DATE) {