Suppress error from lack of player data on login

This commit is contained in:
PikaMug 2021-03-16 23:48:55 -04:00
parent 857b580278
commit 09cf625a8a

View File

@ -850,6 +850,9 @@ public class PlayerListener implements Listener {
final CompletableFuture<Quester> cf = plugin.getStorage().loadQuesterData(evt.getPlayer().getUniqueId());
try {
final Quester quester = cf.get();
if (quester == null) {
return;
}
for (final Quest q : quester.getCompletedQuests()) {
if (q != null) {
if (!quester.getCompletedTimes().containsKey(q) && q.getPlanner().getCooldown() > -1) {