Merge "Using common method 'bool_from_string' from oslo strutils"

This commit is contained in:
Jenkins
2014-01-31 02:38:12 +00:00
committed by Gerrit Code Review
4 changed files with 19 additions and 15 deletions
+1 -5
View File
@@ -49,7 +49,7 @@ def schema_args(schema_getter, omit=[]):
typemap = {
'string': str,
'integer': int,
'boolean': string_to_bool,
'boolean': strutils.bool_from_string,
'array': list
}
@@ -177,10 +177,6 @@ def is_authentication_required(f):
return getattr(f, 'require_authentication', True)
def string_to_bool(arg):
return arg.strip().lower() in ('t', 'true', 'yes', '1')
def env(*vars, **kwargs):
"""Search for the first defined of possibly many env vars