From 4e3c901e5932bd737ec39547c9defb083807fc01 Mon Sep 17 00:00:00 2001 From: Risto Lahtela <24460436+AuroraLS3@users.noreply.github.com> Date: Wed, 10 Mar 2021 09:57:25 +0200 Subject: [PATCH] Reversed regular->inactive metric dates The dates were calculating the metric wrong way around, - the first index was for current time - Regulars - the second index was for 30 days ago - Inactive So it was calculating inactive->regular instead Affects issues: - Fixed #1775 --- .../database/queries/analysis/ActivityIndexQueries.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Plan/common/src/main/java/com/djrapitops/plan/storage/database/queries/analysis/ActivityIndexQueries.java b/Plan/common/src/main/java/com/djrapitops/plan/storage/database/queries/analysis/ActivityIndexQueries.java index 49c2c9408..2c5510f39 100644 --- a/Plan/common/src/main/java/com/djrapitops/plan/storage/database/queries/analysis/ActivityIndexQueries.java +++ b/Plan/common/src/main/java/com/djrapitops/plan/storage/database/queries/analysis/ActivityIndexQueries.java @@ -223,8 +223,8 @@ public class ActivityIndexQueries { return new QueryStatement(selectActivePlayerCount) { @Override public void prepare(PreparedStatement statement) throws SQLException { - setSelectActivityIndexSQLParameters(statement, 1, threshold, serverUUID, end); - setSelectActivityIndexSQLParameters(statement, 12, threshold, serverUUID, start); + setSelectActivityIndexSQLParameters(statement, 1, threshold, serverUUID, start); + setSelectActivityIndexSQLParameters(statement, 12, threshold, serverUUID, end); statement.setDouble(23, ActivityIndex.REGULAR); statement.setDouble(24, 5.1); statement.setDouble(25, -0.1);