From ec219907ec72d6be8ad928d1ab496961e8ddeee5 Mon Sep 17 00:00:00 2001 From: Fuzzlemann Date: Sat, 29 Jul 2017 23:15:53 +0200 Subject: [PATCH] Fixed rounding --- .../com/djrapitops/plan/utilities/analysis/MathUtils.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Plan/src/main/java/com/djrapitops/plan/utilities/analysis/MathUtils.java b/Plan/src/main/java/com/djrapitops/plan/utilities/analysis/MathUtils.java index bf1ea03b0..f085e12b7 100644 --- a/Plan/src/main/java/com/djrapitops/plan/utilities/analysis/MathUtils.java +++ b/Plan/src/main/java/com/djrapitops/plan/utilities/analysis/MathUtils.java @@ -186,11 +186,6 @@ public class MathUtils { * @return The rounded number */ public static double round(double number) { - String formattedNumber = decimalFormat.format(number); - if (formattedNumber.length() > 4) { - formattedNumber = formattedNumber.substring(0, 3); //Fix for unknown reasons for not-rounding - } - - return Double.valueOf(formattedNumber); + return Double.valueOf(decimalFormat.format(number)); } }