Skip to content

Commit

Permalink
Change return type to ComponentLike
Browse files Browse the repository at this point in the history
  • Loading branch information
Warriorrrr committed Jun 12, 2023
1 parent f9f1e5a commit 3484397
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,12 @@ public static Component joinList(List<Component> components, Component delimiter
* @param objects The objects to convert
* @return The formatted list of components
*/
public static List<Component> convert(final @NotNull Object @NotNull... objects) {
final List<Component> components = new ArrayList<>();
public static List<ComponentLike> convert(final @NotNull Object @NotNull... objects) {
final List<ComponentLike> 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()));
}
Expand Down

0 comments on commit 3484397

Please sign in to comment.