From 262fc43026e35bb02900f5ea512251698d462031 Mon Sep 17 00:00:00 2001 From: Shish Date: Thu, 25 Apr 2024 14:43:01 +0100 Subject: [PATCH] [statsd] group by starts_with, not matches --- ext/statsd/main.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ext/statsd/main.php b/ext/statsd/main.php index d9d45756..461cf35c 100644 --- a/ext/statsd/main.php +++ b/ext/statsd/main.php @@ -30,17 +30,17 @@ class StatsDInterface extends Extension { $this->_stats("overall"); - if ($event->page_matches("post/view")) { # 40% + if ($event->page_starts_with("post/view")) { # 40% $this->_stats("post-view"); - } elseif ($event->page_matches("post/list")) { # 30% + } elseif ($event->page_starts_with("post/list")) { # 30% $this->_stats("post-list"); - } elseif ($event->page_matches("user")) { + } elseif ($event->page_starts_with("user")) { $this->_stats("user"); - } elseif ($event->page_matches("upload")) { + } elseif ($event->page_starts_with("upload")) { $this->_stats("upload"); - } elseif ($event->page_matches("rss")) { + } elseif ($event->page_starts_with("rss")) { $this->_stats("rss"); - } elseif ($event->page_matches("api")) { + } elseif ($event->page_starts_with("api")) { $this->_stats("api"); } else { $this->_stats("other");