Skip to content

Commit

Permalink
additional stats bork fix
Browse files Browse the repository at this point in the history
i really should have tested the initial replacement before committing eh
  • Loading branch information
mcmonkey4eva committed Jul 31, 2022
1 parent 6298909 commit 886f8e4
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/main/java/org/mcmonkey/sentinel/metrics/StatsRecord.java
Expand Up @@ -57,8 +57,7 @@ public void run() {
BufferedReader in = null;
try {
// Open a connection to the stats server
URL url = new URL("https://stats.mcmonkey.org/Stats/Submit"
+ URLEncoder.encode(SentinelPlugin.instance.getDescription().getVersion()));
URL url = new URL("https://stats.mcmonkey.org/Stats/Submit");
HttpURLConnection uc = (HttpURLConnection) url.openConnection();
uc.setDoInput(true);
uc.setDoOutput(true);
Expand All @@ -77,7 +76,7 @@ public void run() {
}
catch (Exception e) {
if (SentinelPlugin.debugMe) {
System.out.println("Sentinel stat issue: " + e.getMessage());
System.out.println("Sentinel stat issue: " + e.getClass().getName() + ": " + e.getMessage());
}
}
finally {
Expand All @@ -88,7 +87,7 @@ public void run() {
}
catch (Exception e) {
if (SentinelPlugin.debugMe) {
System.out.println("Sentinel stat issue (backup): " + e.getMessage());
System.out.println("Sentinel stat issue (backup): " + e.getClass().getName() + ": " + e.getMessage());
}
}
}
Expand Down

0 comments on commit 886f8e4

Please sign in to comment.