From 48ba30a616555d0fe9b06cfd92913386478df1b3 Mon Sep 17 00:00:00 2001 From: HappyPikachu Date: Wed, 6 Jul 2016 20:58:33 -0400 Subject: [PATCH] No longer assume quests.yml contains custom1 quest, fixes #369. Bump version number --- pom.xml | 2 +- .../java/me/blackvein/quests/QuestFactory.java | 15 +++++++-------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/pom.xml b/pom.xml index 21c090178..ad03c6772 100644 --- a/pom.xml +++ b/pom.xml @@ -3,7 +3,7 @@ me.blackvein.quests quests - 2.6.7 + 2.6.8 quests https://github.com/FlyingPikachu/Quests/ jar diff --git a/src/main/java/me/blackvein/quests/QuestFactory.java b/src/main/java/me/blackvein/quests/QuestFactory.java index 58acedbe5..184fa5a55 100644 --- a/src/main/java/me/blackvein/quests/QuestFactory.java +++ b/src/main/java/me/blackvein/quests/QuestFactory.java @@ -1103,21 +1103,20 @@ public class QuestFactory implements ConversationAbandonedListener, ColorUtil { } if (edit != null) { - ConfigurationSection questList = cs.getParent(); for (String key : questList.getKeys(false)) { - String name = questList.getString(key + ".name"); - if (name.equalsIgnoreCase(edit)) { + + if (name != null) { + if (name.equalsIgnoreCase(edit)) { - questList.set(key, null); - break; - - } + questList.set(key, null); + break; + } + } } - } String name = (String) cc.getSessionData(CK.Q_NAME);