Remove an unused method in novaclient/shell.py
The 'positive_non_zero_float' method has not been used since Ifc9ddc08614e28358229db84cb9b54552ca36d51. TrivialFix Change-Id: Ice0c8f15dbc1a027710e0ace6c8fa872b964c3b6
This commit is contained in:
parent
d63800d5ec
commit
8691eeccd8
@ -211,20 +211,6 @@ class DeprecatedAction(argparse.Action):
|
||||
action(parser, namespace, values, option_string)
|
||||
|
||||
|
||||
def positive_non_zero_float(text):
|
||||
if text is None:
|
||||
return None
|
||||
try:
|
||||
value = float(text)
|
||||
except ValueError:
|
||||
msg = _("%s must be a float") % text
|
||||
raise argparse.ArgumentTypeError(msg)
|
||||
if value <= 0:
|
||||
msg = _("%s must be greater than 0") % text
|
||||
raise argparse.ArgumentTypeError(msg)
|
||||
return value
|
||||
|
||||
|
||||
class SecretsHelper(object):
|
||||
def __init__(self, args, client):
|
||||
self.args = args
|
||||
|
Loading…
x
Reference in New Issue
Block a user