Closed Thesam1798 closed 6 months ago
This is a problem with laravel. Technically 0
and 1
are valid boolean values.
Many of my eggs use the following for bool values.
"required|string|in:true,false"
I tried that, but the parser puts it in string and not in boolean in the json.
By the way, it does the same thing with strings that have only numbers, it converts to int...
I also have this problem. Also with decimal numbers that become strings.
It might be a good idea to be able to specify a value type to the parser, something like this:
{
"config.json": {
"parser": "json",
"find": {
"a2sQueryEnabled": "{{server.build.env.QUERY_PORT_ENABLED;boolean}}"
}
}
}
Still no way around this?
Current Behavior
Currently, in the Configuration Files of the nest, if the json parser is assigned and the environment variable is set to boolean, it puts
0
or1
in the json file.Expected Behavior
If the environment variable is boolean, it should put
true
orfalse
in the json file.Steps to Reproduce
Create an environment variable
QUERY_PORT_ENABLED
in boolean. Set the value to true. Define inConfiguration Files
of the nest a json parser like this:Create a server and check the
config.json
filePanel Version
1.10.4
Wings Version
1.7.2
Games and/or Eggs Affected
All
Docker Image
All
Error Logs
Is there an existing issue for this?