58
58
return bool_from_string(subject) and 1 or 0
62
62
"""Interpret a string as a boolean.
64
64
A case-insensitive match is performed such that strings matching 't',
65
65
'true', 'on', 'y', 'yes', or '1' are considered True and, when
68
68
Useful for JSON-decoded stuff and config file parsing.