From 6d6a6f365c4b5e6ec73c428a0667452fd2ae14a3 Mon Sep 17 00:00:00 2001 From: Michael Filion Date: Mon, 17 Apr 2017 11:39:53 -0400 Subject: [PATCH] Fixing issue in index.php with undefined index when first connecting * This closes issue #3 --- index.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/index.php b/index.php index 8a40c32..61ca49b 100644 --- a/index.php +++ b/index.php @@ -33,7 +33,14 @@
' . count($stats['users']) . ''; +$connected_clients = 0; +if(array_key_exists('users', $stats)) +{ + $connected_clients = count($stats['users']); +} +echo ' +

' . $connected_clients . '

+'; ?>

Connected Clients