mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2024-12-23 09:47:38 +00:00
Throw error instead of returning null on a boolean return
This commit is contained in:
parent
bdd3bc26af
commit
4534154894
@ -73,7 +73,7 @@ public class PrimitiveBindings extends Bindings {
|
|||||||
public Boolean getBoolean(String argument) {
|
public Boolean getBoolean(String argument) {
|
||||||
switch (argument.toLowerCase(Locale.ROOT)) {
|
switch (argument.toLowerCase(Locale.ROOT)) {
|
||||||
case "":
|
case "":
|
||||||
return null;
|
throw new InputParseException("Invalid empty string instead of boolean");
|
||||||
case "true":
|
case "true":
|
||||||
case "yes":
|
case "yes":
|
||||||
case "on":
|
case "on":
|
||||||
|
Loading…
Reference in New Issue
Block a user