From d34d774307d89e68e401bdb0f3531478bd3f1984 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pascal=20B=C3=BCrklin?= Date: Wed, 6 Oct 2021 15:46:31 +0200 Subject: [PATCH] Fix NPE --- src/main/java/me/libraryaddict/disguise/DisguiseConfig.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/me/libraryaddict/disguise/DisguiseConfig.java b/src/main/java/me/libraryaddict/disguise/DisguiseConfig.java index e354e47f..db4279be 100644 --- a/src/main/java/me/libraryaddict/disguise/DisguiseConfig.java +++ b/src/main/java/me/libraryaddict/disguise/DisguiseConfig.java @@ -687,7 +687,8 @@ public class DisguiseConfig { DisguiseUtilities.getLogger().warning("Cannot parse '" + config.getString("UpdatesBranch") + "' to a valid option for UpdatesBranch"); } - PermissionDefault commandVisibility = PermissionDefault.getByName(config.getString("Permissions.SeeCommands")); + String seeCommands = config.getString("Permissions.SeeCommands"); + PermissionDefault commandVisibility = seeCommands == null ? null : PermissionDefault.getByName(seeCommands); if (commandVisibility == null) { DisguiseUtilities.getLogger()