From d406e2aae20f20a7df6fc77d9317323de043c0f6 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Sat, 24 Feb 2018 14:38:28 -0800 Subject: siteinfo.json - if hide_in_statistics is set only include the total channels count and no other statistical info --- include/network.php | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/include/network.php b/include/network.php index 0824183f7..f8cb68613 100644 --- a/include/network.php +++ b/include/network.php @@ -1617,13 +1617,16 @@ function get_site_info() { 'lastpoll' => get_config('system','lastpoll'), 'info' => (($site_info) ? $site_info : ''), 'channels_total' => $channels_total_stat, - 'channels_active_halfyear' => $channels_active_halfyear_stat, - 'channels_active_monthly' => $channels_active_monthly_stat, - 'local_posts' => $local_posts_stat, - 'local_comments' => $local_comments_stat, 'hide_in_statistics' => $hide_in_statistics ]; + if(! $hide_in_statistics) { + $data['channels_active_halfyear'] = $channels_active_halfyear_stat; + $data['channels_active_monthly'] = $channels_active_monthly_stat; + $data['local_posts'] = $local_posts_stat; + $data['local_comments'] = $local_comments_stat; + } + return $data; } -- cgit v1.2.3