diff options
author | Mario <mario@mariovavti.com> | 2023-02-28 09:29:39 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2023-02-28 09:29:39 +0000 |
commit | ca0bd3ed3251e2558dc4a53abed417dd9da6244d (patch) | |
tree | f35d955a3132321dff11b4654bb5556b2e458975 /Zotlabs | |
parent | 7dacc7c2688199f8d73a2a33fbdfdd840fc62d77 (diff) | |
download | volse-hubzilla-ca0bd3ed3251e2558dc4a53abed417dd9da6244d.tar.gz volse-hubzilla-ca0bd3ed3251e2558dc4a53abed417dd9da6244d.tar.bz2 volse-hubzilla-ca0bd3ed3251e2558dc4a53abed417dd9da6244d.zip |
fix some php warnings
Diffstat (limited to 'Zotlabs')
-rw-r--r-- | Zotlabs/Lib/ActivityStreams.php | 4 | ||||
-rw-r--r-- | Zotlabs/Module/Hq.php | 2 | ||||
-rw-r--r-- | Zotlabs/Widget/Pinned.php | 6 |
3 files changed, 7 insertions, 5 deletions
diff --git a/Zotlabs/Lib/ActivityStreams.php b/Zotlabs/Lib/ActivityStreams.php index 1a6fe9c1b..cfed53b3c 100644 --- a/Zotlabs/Lib/ActivityStreams.php +++ b/Zotlabs/Lib/ActivityStreams.php @@ -182,11 +182,11 @@ class ActivityStreams { $values = $this->objprop($field); if ($values) { $values = force_array($values); - $tmp[$field] = (($tmp[$field]) ? array_merge($tmp[$field], $values) : $values); + $tmp[$field] = ((isset($tmp[$field])) ? array_merge($tmp[$field], $values) : $values); $result = array_values(array_unique(array_merge($result, $values))); } // remove duplicates - if (is_array($tmp[$field])) { + if (isset($tmp[$field])) { $tmp[$field] = array_values(array_unique($tmp[$field])); } } diff --git a/Zotlabs/Module/Hq.php b/Zotlabs/Module/Hq.php index df30f933d..58f3e5ef2 100644 --- a/Zotlabs/Module/Hq.php +++ b/Zotlabs/Module/Hq.php @@ -245,7 +245,7 @@ class Hq extends \Zotlabs\Web\Controller { $options['offset'] = $_REQUEST['offset'] ?? 0; $options['type'] = $_REQUEST['type'] ?? ''; - $options['author'] = $_REQUEST['author'] ? urldecode($_REQUEST['author']) : ''; + $options['author'] = ((isset($_REQUEST['author'])) ? urldecode($_REQUEST['author']) : ''); $ret = Messages::get_messages_page($options); diff --git a/Zotlabs/Widget/Pinned.php b/Zotlabs/Widget/Pinned.php index 88a87d0fe..6d2618deb 100644 --- a/Zotlabs/Widget/Pinned.php +++ b/Zotlabs/Widget/Pinned.php @@ -42,6 +42,8 @@ class Pinned { $observer = \App::get_observer(); + xchan_query($items); + foreach($items as $item) { $midb64 = gen_link_id($item['mid']); @@ -49,8 +51,8 @@ class Pinned { if(isset($observer['xchan_hash']) && in_array($observer['xchan_hash'], get_pconfig($item['uid'], 'pinned_hide', $midb64, []))) continue; - $author = channelx_by_hash($item['author_xchan']); - $owner = channelx_by_hash($item['owner_xchan']); + $author = $item['author']; + $owner = $item['owner']; $profile_avatar = $author['xchan_photo_m']; $profile_link = chanlink_hash($item['author_xchan']); |