From 90aea4a9cc90596c8ecfee6487307f321847dd8b Mon Sep 17 00:00:00 2001 From: Rainnny7 Date: Mon, 22 Apr 2024 23:12:02 -0400 Subject: [PATCH] yes --- .../java/me/braydon/mc/common/EnvironmentUtils.java | 10 ---------- .../java/me/braydon/mc/service/MaxMindService.java | 2 +- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/API/src/main/java/me/braydon/mc/common/EnvironmentUtils.java b/API/src/main/java/me/braydon/mc/common/EnvironmentUtils.java index 7f8812f..0f37cfa 100644 --- a/API/src/main/java/me/braydon/mc/common/EnvironmentUtils.java +++ b/API/src/main/java/me/braydon/mc/common/EnvironmentUtils.java @@ -35,19 +35,9 @@ public final class EnvironmentUtils { * Is the app running in a production environment? */ @Getter private static final boolean production; - - /** - * Is the app running in a test environment? - */ - @Getter private static boolean testing; - static { // Are we running on production? String appEnv = System.getenv("APP_ENV"); production = appEnv != null && (appEnv.equals("production")); - - // Are we running on a test environment? - String testEnv = System.getenv("SPRING_TEST"); - testing = testEnv != null && (testEnv.equals("true")); } } \ No newline at end of file diff --git a/API/src/main/java/me/braydon/mc/service/MaxMindService.java b/API/src/main/java/me/braydon/mc/service/MaxMindService.java index 34b278e..98d1e5e 100644 --- a/API/src/main/java/me/braydon/mc/service/MaxMindService.java +++ b/API/src/main/java/me/braydon/mc/service/MaxMindService.java @@ -72,7 +72,7 @@ public final class MaxMindService { @PostConstruct public void onInitialize() { // Load the databases - if (!EnvironmentUtils.isTesting()) { + if (EnvironmentUtils.isProduction()) { loadDatabases(); } }