Skip to content

Commit

Permalink
Fix give command for tipped arrow item (#5627)
Browse files Browse the repository at this point in the history
  • Loading branch information
TiagoFar78 authored Feb 4, 2024
1 parent 388d571 commit 04c0165
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -542,9 +542,9 @@ public void addPotionMeta(final CommandSource sender, final boolean allowShortNa
pmeta.addCustomEffect(pEffect, true);
stack.setItemMeta(pmeta);
if (VersionUtil.getServerBukkitVersion().isHigherThanOrEqualTo(VersionUtil.v1_9_R01)) {
if (isSplashPotion && stack.getType() != Material.SPLASH_POTION) {
if (isSplashPotion && stack.getType() == Material.POTION) {
stack.setType(Material.SPLASH_POTION);
} else if (!isSplashPotion && stack.getType() != Material.POTION) {
} else if (!isSplashPotion && stack.getType() == Material.SPLASH_POTION) {
stack.setType(Material.POTION);
}
} else {
Expand Down

0 comments on commit 04c0165

Please sign in to comment.