diff options
author | Jenkins <jenkins@review.openstack.org> | 2014-09-03 12:31:39 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2014-09-03 12:31:39 +0000 |
commit | 281df4b601a5a532353655a7e960dacb5cab0e25 (patch) | |
tree | 0a6a8bbd0316d149d45bbb6a62067476ff8efce6 | |
parent | e81ecac6fcd3c84e01dcc89c7fd7d637c0733783 (diff) | |
parent | fc069d154b4a504d1611cfcfb783ee68067961f4 (diff) | |
download | oslo-utils-281df4b601a5a532353655a7e960dacb5cab0e25.tar.gz |
Merge "Just use int(BOOL) to convert to 1 or 0"
-rw-r--r-- | oslo/utils/strutils.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/oslo/utils/strutils.py b/oslo/utils/strutils.py index 5550e77..26da39b 100644 --- a/oslo/utils/strutils.py +++ b/oslo/utils/strutils.py @@ -94,7 +94,7 @@ def int_from_bool_as_string(subject): Useful for JSON-decoded stuff and config file parsing """ - return bool_from_string(subject) and 1 or 0 + return int(bool_from_string(subject)) def bool_from_string(subject, strict=False, default=False): |