Merge "Fix prompt message for qos-bandwidth-limit-rule-create"

This commit is contained in:
Jenkins 2016-08-24 23:29:45 +00:00 committed by Gerrit Code Review
commit 64e8c3e21a

View File

@ -27,18 +27,18 @@ BANDWIDTH_LIMIT_RULE_RESOURCE = 'bandwidth_limit_rule'
def add_bandwidth_limit_arguments(parser):
parser.add_argument(
'--max-kbps',
help=_('max bandwidth in kbps.'))
help=_('Maximum bandwidth in kbps.'))
parser.add_argument(
'--max-burst-kbps',
help=_('max burst bandwidth in kbps.'))
help=_('Maximum burst bandwidth in kbps.'))
def update_bandwidth_limit_args2body(parsed_args, body):
max_kbps = parsed_args.max_kbps
max_burst_kbps = parsed_args.max_burst_kbps
if not (max_kbps or max_burst_kbps):
raise exceptions.CommandError(_("Must provide max_kbps"
" or max_burst_kbps option."))
raise exceptions.CommandError(_("Must provide max-kbps"
" or max-burst-kbps option."))
neutronv20.update_dict(parsed_args, body,
['max_kbps', 'max_burst_kbps', 'tenant_id'])