diff options
author | Mario <mario@mariovavti.com> | 2021-03-10 13:16:08 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2021-03-10 13:16:08 +0000 |
commit | f8447521a84c0eb30c08da212e8156256558617b (patch) | |
tree | 62a8e527517a19ed18928aaeff3314d680f94b9f /include | |
parent | 15faf01ec960fff88a1f9c83fb6d251319cecea7 (diff) | |
download | volse-hubzilla-f8447521a84c0eb30c08da212e8156256558617b.tar.gz volse-hubzilla-f8447521a84c0eb30c08da212e8156256558617b.tar.bz2 volse-hubzilla-f8447521a84c0eb30c08da212e8156256558617b.zip |
php8: random fixes deriving from mod network
Diffstat (limited to 'include')
-rw-r--r-- | include/conversation.php | 6 | ||||
-rw-r--r-- | include/items.php | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/include/conversation.php b/include/conversation.php index ae69b7a01..f3e5fafa7 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -865,7 +865,7 @@ function conversation($items, $mode, $update, $page_mode = 'traditional', $prepa $x = [ 'mode' => $mode, 'item' => $item ]; call_hooks('stream_item',$x); - if($x['item']['blocked']) + if(isset($x['item']['blocked'])) continue; $item = $x['item']; @@ -1563,7 +1563,7 @@ function sort_item_children($items) { $result = $items; usort($result,'sort_thr_created_rev'); foreach($result as $k => $i) { - if($result[$k]['children']) { + if(isset($result[$k]['children'])) { $result[$k]['children'] = sort_item_children($result[$k]['children']); } } @@ -1573,7 +1573,7 @@ function sort_item_children($items) { function add_children_to_list($children, &$arr) { foreach($children as $y) { $arr[] = $y; - if($y['children']) + if(isset($y['children'])) add_children_to_list($y['children'], $arr); } } diff --git a/include/items.php b/include/items.php index a1198bb4d..c6a5f40a6 100644 --- a/include/items.php +++ b/include/items.php @@ -1432,7 +1432,7 @@ function purify_imported_object($obj) { elseif (is_string($obj)) { $ret = purify_html($obj); } - + return $ret; } @@ -4334,8 +4334,8 @@ function fetch_post_tags($items, $link = false) { foreach($imeta as $i) { if(array_key_exists('item_id',$items[$x])) { if($i['iid'] == $items[$x]['item_id']) { - if(! is_array($items[$x]['iconfig'])) - $items[$x]['iconfig'] = array(); + if(! isset($items[$x]['iconfig'])) + $items[$x]['iconfig'] = []; $i['v'] = ((preg_match('|^a:[0-9]+:{.*}$|s',$i['v'])) ? unserialize($i['v']) : $i['v']); $items[$x]['iconfig'][] = $i; } |