Skip to content

Commit 4903d27

Browse files
authored
change strtobool to ignore the to bool conversion
when the input value is a bool
1 parent aae58b5 commit 4903d27

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

decouple.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@
3131
FALSE_VALUES = {"n", "no", "f", "false", "off", "0"}
3232

3333
def strtobool(value):
34+
if isinstance(value, bool):
35+
return value
3436
value = value.lower()
3537

3638
if value in TRUE_VALUES:

0 commit comments

Comments
 (0)