From f3982d78c090f33c67301cdd7f34deb8f2064e22 Mon Sep 17 00:00:00 2001 From: szymon Date: Sat, 2 Jan 2021 17:20:56 +0100 Subject: [PATCH] . --- .../szum123321/textile_backup/core/Utilities.java | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/src/main/java/net/szum123321/textile_backup/core/Utilities.java b/src/main/java/net/szum123321/textile_backup/core/Utilities.java index d494358..5a72687 100644 --- a/src/main/java/net/szum123321/textile_backup/core/Utilities.java +++ b/src/main/java/net/szum123321/textile_backup/core/Utilities.java @@ -96,10 +96,7 @@ public class Utilities { } } - for(String i : Statics.CONFIG.fileBlacklist) { - if(path.startsWith(i)) - return true; - } + for(String i : Statics.CONFIG.fileBlacklist) if(path.startsWith(i)) return true; return false; } @@ -170,12 +167,9 @@ public class Utilities { public static String formatDuration(Duration duration) { DateTimeFormatter formatter; - if(duration.toHours() > 0) - formatter = DateTimeFormatter.ofPattern("HH:mm:ss.SSS"); - else if(duration.toMinutes() > 0) - formatter = DateTimeFormatter.ofPattern("mm:ss.SSS"); - else - formatter = DateTimeFormatter.ofPattern("ss.SSS"); + if(duration.toHours() > 0) formatter = DateTimeFormatter.ofPattern("HH:mm:ss.SSS"); + else if(duration.toMinutes() > 0) formatter = DateTimeFormatter.ofPattern("mm:ss.SSS"); + else formatter = DateTimeFormatter.ofPattern("ss.SSS"); return LocalTime.ofNanoOfDay(duration.toNanos()).format(formatter); }