From df479f1d5d62d1b9c25c6908782f97aed4720a40 Mon Sep 17 00:00:00 2001 From: Jeroen <48769316+iTwins@users.noreply.github.com> Date: Wed, 30 Aug 2023 00:10:25 +0200 Subject: [PATCH] use String.valueOf instead of appending to empty string --- .../io/github/thebusybiscuit/slimefun4/core/debug/Debug.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/core/debug/Debug.java b/src/main/java/io/github/thebusybiscuit/slimefun4/core/debug/Debug.java index cf7687dc9f..50a05c309e 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/core/debug/Debug.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/core/debug/Debug.java @@ -106,7 +106,7 @@ public static void log(@Nonnull String test, @Nonnull String msg, @Nonnull Objec while ((i = msg.indexOf('{', i)) != -1 && msg.charAt(i + 1) == '}') { // Substring up to the opening brace `{`, add the variable for this and add the rest of the message msg = msg.substring(0, i) + vars[idx] + msg.substring(i + 2); - i += ("" + vars[idx++]).length(); + i += String.valueOf(vars[idx++]).length(); } return msg;