From 348439787f63dea14eb3672a55dc44ca07b46c68 Mon Sep 17 00:00:00 2001 From: Warrior <50800980+Warriorrrr@users.noreply.github.com> Date: Wed, 26 Apr 2023 21:46:32 +0200 Subject: [PATCH] Change return type to ComponentLike --- .../com/palmergames/bukkit/towny/utils/TownyComponents.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Towny/src/main/java/com/palmergames/bukkit/towny/utils/TownyComponents.java b/Towny/src/main/java/com/palmergames/bukkit/towny/utils/TownyComponents.java index 2f16ba11f2..27981c6066 100644 --- a/Towny/src/main/java/com/palmergames/bukkit/towny/utils/TownyComponents.java +++ b/Towny/src/main/java/com/palmergames/bukkit/towny/utils/TownyComponents.java @@ -91,12 +91,12 @@ public static Component joinList(List components, Component delimiter * @param objects The objects to convert * @return The formatted list of components */ - public static List convert(final @NotNull Object @NotNull... objects) { - final List components = new ArrayList<>(); + public static List convert(final @NotNull Object @NotNull... objects) { + final List components = new ArrayList<>(); for (Object object : objects) { if (object instanceof ComponentLike like) - components.add(like.asComponent()); + components.add(like); else components.add(miniMessage(object.toString())); }