From d6ad57b60ff862ed4375fb2a384518893727faa6 Mon Sep 17 00:00:00 2001 From: Sfiguz7 Date: Wed, 22 Sep 2021 21:45:09 +0200 Subject: [PATCH] More formatting --- .../slimefun4/utils/SlimefunUtils.java | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/src/main/java/io/github/thebusybiscuit/slimefun4/utils/SlimefunUtils.java b/src/main/java/io/github/thebusybiscuit/slimefun4/utils/SlimefunUtils.java index 197b26a1c..4cef7c4d3 100644 --- a/src/main/java/io/github/thebusybiscuit/slimefun4/utils/SlimefunUtils.java +++ b/src/main/java/io/github/thebusybiscuit/slimefun4/utils/SlimefunUtils.java @@ -159,7 +159,8 @@ public final class SlimefunUtils { * @param item * The {@link ItemStack} you want to add/remove Soulbound from. * @param makeSoulbound - * If they item should be soulbound. + * If the item should be soulbound. + * * @see #isSoulbound(ItemStack) */ public static void setSoulbound(@Nullable ItemStack item, boolean makeSoulbound) { @@ -211,7 +212,7 @@ public final class SlimefunUtils { * The result will be a Player Head with this texture. * * @param texture - * The texture for this head (base64 or hash) + * The texture for this head (base64 or hash) * @return An {@link ItemStack} with this Head texture */ public static @Nonnull ItemStack getCustomHead(@Nonnull String texture) { @@ -308,8 +309,8 @@ public final class SlimefunUtils { if (itemMeta.hasLore() && itemLore.isPresent() && !itemMeta.getLore().equals(itemLore.get())) { return false; - } else { - return itemMeta.hasLore() == itemLore.isPresent(); + } else if (itemMeta.hasLore() != itemLore.isPresent()) { + return false; } } @@ -450,6 +451,7 @@ public final class SlimefunUtils { * The {@link ItemSpawnReason} why the item is being dropped * @param addRandomOffset * Whether a random offset should be added (see {@link World#dropItemNaturally(Location, ItemStack)}) + * * @return The dropped {@link Item} (or null if the {@link SlimefunItemSpawnEvent} was cancelled) */ @ParametersAreNonnullByDefault @@ -475,9 +477,13 @@ public final class SlimefunUtils { * This method automatically calls a {@link SlimefunItemSpawnEvent} to allow * other plugins to catch the item being dropped. * - * @param loc The {@link Location} where to drop the item - * @param item The {@link ItemStack} to drop - * @param reason The {@link ItemSpawnReason} why the item is being dropped + * @param loc + * The {@link Location} where to drop the item + * @param item + * The {@link ItemStack} to drop + * @param reason + * The {@link ItemSpawnReason} why the item is being dropped + * * @return The dropped {@link Item} (or null if the {@link SlimefunItemSpawnEvent} was cancelled) */ @ParametersAreNonnullByDefault