Generate true/false for _DEFAULT_ON options (#22829)
This commit is contained in:
parent
ee3540e8df
commit
71257e21e6
3 changed files with 50 additions and 48 deletions
|
@ -513,7 +513,7 @@ def _config_to_json(key_type, config_value):
|
|||
else:
|
||||
return list(map(str.strip, config_value.split(',')))
|
||||
|
||||
elif key_type == 'bool':
|
||||
elif key_type in ['bool', 'flag']:
|
||||
if isinstance(config_value, bool):
|
||||
return config_value
|
||||
return config_value in true_values
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue