From 48ac619599d5c737a92786b8156979fea25aba49 Mon Sep 17 00:00:00 2001 From: Hypolite Petovan Date: Mon, 10 May 2021 21:52:26 -0400 Subject: [PATCH] Check unparseURL parameter type in APContact::getByURL - Address https://github.com/friendica/friendica/issues/10167#issuecomment-832421258 --- src/Model/APContact.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/APContact.php b/src/Model/APContact.php index 863496dbb..cc84df4a5 100644 --- a/src/Model/APContact.php +++ b/src/Model/APContact.php @@ -235,7 +235,7 @@ class APContact unset($parts['path']); if (empty($apcontact['addr'])) { - if (!empty($apcontact['nick'])) { + if (!empty($apcontact['nick']) && is_array($parts)) { $apcontact['addr'] = $apcontact['nick'] . '@' . str_replace('//', '', Network::unparseURL($parts)); } else { $apcontact['addr'] = '';