Skip to content

Conversation

@Marcono1234
Copy link
Contributor

Fixes #600

Java's Boolean.parseBoolean(String) returns for any non-"true" string false.
This is extremely error-prone because for strings like "yes" the user likely does not expect false.

This pull request changes the methods which were previously using parseBoolean(...) to now only accept "true" or "false" (case insensitive) and to throw exceptions for any other value.

Boolean.parseBoolean(String) returns for any non-"true" string false.
This is extremely error-prone because for strings like "yes" the user
likely does not expect false.

Now the methods which were previously using parseBoolean(...) only accept
"true" or "false" (case insensitive) and throw exceptions for any other
value.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Boolean no error passing a String value

1 participant