From 10d1cbd3ce58fb868a42d1425f62f908df395e7d Mon Sep 17 00:00:00 2001 From: Mario Date: Tue, 14 May 2024 09:00:43 +0000 Subject: php warnings/errors --- Zotlabs/Lib/Activity.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Zotlabs/Lib/Activity.php b/Zotlabs/Lib/Activity.php index 75d2ffbe9..b819ef0f7 100644 --- a/Zotlabs/Lib/Activity.php +++ b/Zotlabs/Lib/Activity.php @@ -1727,9 +1727,12 @@ class Activity { foreach ($links as $link) { if (is_array($link) && array_key_exists('mediaType', $link) && $link['mediaType'] === 'text/html') { $profile = $link['href']; + } elseif (is_string($link)) { + $profile = $link; + break; } } - if (!$profile) { + if (!$profile && isset($links[0]['href'])) { $profile = $links[0]['href']; } } -- cgit v1.2.3