Fix NPE for vault getUserMeta when defaultValue is null and the LP value is also null
This commit is contained in:
parent
9b8d6e1dc7
commit
378f3f5efa
@ -153,7 +153,12 @@ public class VaultChatHook extends Chat {
|
|||||||
return defaultValue;
|
return defaultValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
return unescapeCharacters(user.getUserData().getMetaData(perms.createContextForWorld(world)).getMeta().getOrDefault(node, defaultValue));
|
String ret = user.getUserData().getMetaData(perms.createContextForWorld(world)).getMeta().get(node);
|
||||||
|
if (ret == null) {
|
||||||
|
return defaultValue;
|
||||||
|
} else {
|
||||||
|
return unescapeCharacters(ret);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private String getUserChatMeta(boolean prefix, User user, String world) {
|
private String getUserChatMeta(boolean prefix, User user, String world) {
|
||||||
|
Loading…
Reference in New Issue
Block a user