diff options
author | Simon Rettberg | 2021-03-12 14:00:42 +0100 |
---|---|---|
committer | Simon Rettberg | 2021-03-12 14:00:42 +0100 |
commit | a1d4b318cf8e99d41e1038d7b17521aa6e324972 (patch) | |
tree | f69ee24091c69f149cf96492de24533c2189b94d /modules-available/statistics/inc | |
parent | [eventlog] Linkify Client-UUIDs in Server-Log (diff) | |
download | slx-admin-a1d4b318cf8e99d41e1038d7b17521aa6e324972.tar.gz slx-admin-a1d4b318cf8e99d41e1038d7b17521aa6e324972.tar.xz slx-admin-a1d4b318cf8e99d41e1038d7b17521aa6e324972.zip |
[statistics] Fix clientip != filter
References #3842
Diffstat (limited to 'modules-available/statistics/inc')
-rw-r--r-- | modules-available/statistics/inc/statisticsfilter.inc.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/modules-available/statistics/inc/statisticsfilter.inc.php b/modules-available/statistics/inc/statisticsfilter.inc.php index 4a4899e2..ecb1f6b4 100644 --- a/modules-available/statistics/inc/statisticsfilter.inc.php +++ b/modules-available/statistics/inc/statisticsfilter.inc.php @@ -564,7 +564,8 @@ class IpStatisticsFilter extends StatisticsFilter Message::addError('invalid-ip-address', $argument); return '0'; } - return "clientip LIKE '" . str_replace('*', '%', $argument) . "'"; + $operator = $operator[0] === '!' ? 'NOT LIKE' : 'LIKE'; + return "clientip $operator '" . str_replace('*', '%', $argument) . "'"; } } |