Fix incorrect usage of getItemInMainHand() (#145)

This commit is contained in:
MrMacor authored and GitHub committed 2021-05-21 18:29:25 -07:00
1 parent a682d0dd59
commit 035c495691
1 file changed
+1 -1
@@ -66,7 +66,7 @@ public final class CarbonPlayerBukkit extends CarbonPlayerCommon {
if (mainHand != null && !mainHand.getType().isAir()) {
itemStack = mainHand;
} else {
final @Nullable ItemStack offHand = player.getInventory().getItemInMainHand();
final @Nullable ItemStack offHand = player.getInventory().getItemInOffHand();
if (offHand != null && !offHand.getType().isAir()) {
itemStack = offHand;