Safety check for Github #240

This commit is contained in:
HappyPikachu 2018-01-17 19:47:17 -05:00
parent 8decd360db
commit 680112958c
2 changed files with 3 additions and 3 deletions

View File

@ -717,8 +717,8 @@ public class PlayerListener implements Listener {
}
}
if (isPlayer) {
if (plugin.getQuester(evt.getPlayer().getUniqueId()) != null) {
Quester quester = plugin.getQuester(evt.getPlayer().getUniqueId());
if (quester != null) {
for (Quest quest : quester.currentQuests.keySet()) {
if (quester.hasObjective(quest, "reachLocation")) {
quester.reachLocation(quest, evt.getTo());

View File

@ -1868,7 +1868,7 @@ public class Quests extends JavaPlugin implements ConversationAbandonedListener
player.sendMessage(s);
}
} catch (NullPointerException e) {
getLogger().severe("Objectives were null for " + q.name + ". Include quests.yml in Github report");
getLogger().severe("Objectives were null for " + q.name + ". Include quests.yml in Github #238");
e.printStackTrace();
}
}