From 3596bfc263dbeabba918097cea379298b3501d8b Mon Sep 17 00:00:00 2001 From: yoyosource Date: Sun, 4 Apr 2021 19:00:46 +0200 Subject: [PATCH] Hotfix MWTeam NoSuchElementException --- src/de/steamwar/misslewars/MWTeam.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/de/steamwar/misslewars/MWTeam.java b/src/de/steamwar/misslewars/MWTeam.java index 4f11d7b..1e87141 100644 --- a/src/de/steamwar/misslewars/MWTeam.java +++ b/src/de/steamwar/misslewars/MWTeam.java @@ -72,6 +72,9 @@ public class MWTeam { } public void givePlayerItem(ItemStack item) { + if (players.isEmpty()) { + return; + } Player p = players.removeFirst(); players.addLast(p);