mirror of
https://github.com/PikaMug/Quests.git
synced 2024-11-14 22:55:54 +01:00
Catch NPE for #362
This commit is contained in:
parent
da3d4e0295
commit
770acbce5f
@ -595,7 +595,12 @@ public class Quester {
|
||||
}
|
||||
int index2 = 0;
|
||||
for (ItemStack is : getCurrentStage(quest).itemsToDeliver) {
|
||||
int delivered = getQuestData(quest).itemsDelivered.get(is);
|
||||
int delivered = 0;
|
||||
try {
|
||||
delivered = getQuestData(quest).itemsDelivered.get(is);
|
||||
} catch (NullPointerException ne) {
|
||||
plugin.getLogger().severe("itemsDelivered did not contain " + is.getType() + ":" + is.getDurability() + " x " + is.getAmount() + " for quest " + quest.name);
|
||||
}
|
||||
int amt = is.getAmount();
|
||||
Integer npc = getCurrentStage(quest).itemDeliveryTargets.get(index2);
|
||||
index2++;
|
||||
|
Loading…
Reference in New Issue
Block a user