From aee87e3d01ca313766797713e526b8b83700e4bf Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Thu, 22 Sep 2022 12:19:43 +0000 Subject: [PATCH] fix stats users --- src/Appwrite/Usage/Stats.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Appwrite/Usage/Stats.php b/src/Appwrite/Usage/Stats.php index 20ab58b68d..e4d5640ea7 100644 --- a/src/Appwrite/Usage/Stats.php +++ b/src/Appwrite/Usage/Stats.php @@ -108,12 +108,12 @@ class Stats $value = $this->params[$metric] ?? 0; if ($value >= 1) { $this->statsd->increment($metric . $tags); - } - if($metric == $usersMetrics[0]) { - $this->statsd->increment('users.{scope}.count.total' . $tags); - } - if($metric == $usersMetrics[3]) { - $this->statsd->decrement('users.{scope}.count.total' . $tags); + if($metric == $usersMetrics[0]) { + $this->statsd->increment('users.{scope}.count.total' . $tags); + } + if($metric == $usersMetrics[3]) { + $this->statsd->decrement('users.{scope}.count.total' . $tags); + } } }