diff options
author | Rick Harris <rconradharris@gmail.com> | 2013-05-14 15:23:55 +0000 |
---|---|---|
committer | Rick Harris <rconradharris@gmail.com> | 2013-05-17 21:31:37 +0000 |
commit | 715435c816b51b6ec8d38453326eecd35c339fd9 (patch) | |
tree | 9abb8681c1f9b37af56d63214df34301c6d7f027 /nova/utils.py | |
parent | 55ccdbc3bc62dc32161112a77c0fed39e73ee7b4 (diff) | |
download | nova-715435c816b51b6ec8d38453326eecd35c339fd9.tar.gz nova-715435c816b51b6ec8d38453326eecd35c339fd9.tar.xz nova-715435c816b51b6ec8d38453326eecd35c339fd9.zip |
Use strict=True instead of `is_valid_boolstr`
Oslo's `bool_from_string` learned the `strict` keyword which allows
callers to detect invalid boolean values, so we can use that instead
of having a new Nova-specific function.
Change-Id: I61bfa4029897c7304bd54d6cdae9f9a9bc4c1f78
Diffstat (limited to 'nova/utils.py')
-rw-r--r-- | nova/utils.py | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/nova/utils.py b/nova/utils.py index 3020781c8..3e9d8c597 100644 --- a/nova/utils.py +++ b/nova/utils.py @@ -605,12 +605,6 @@ def is_int_like(val): return False -def is_valid_boolstr(val): - """Check if the provided string is a valid bool string or not.""" - boolstrs = ('true', 'false', 'yes', 'no', 'y', 'n', '1', '0') - return str(val).lower() in boolstrs - - def is_valid_ipv4(address): """Verify that address represents a valid IPv4 address.""" try: |