record-create/update: Account for priority being 0
Change-Id: Ia791e602d217cbf21fc8b636b0688c012a538169
This commit is contained in:
parent
030889e549
commit
68b489985d
@ -100,7 +100,7 @@ class CreateRecordCommand(base.CreateCommand):
|
||||
if parsed_args.ttl is not None:
|
||||
record.ttl = parsed_args.ttl
|
||||
|
||||
if parsed_args.priority:
|
||||
if parsed_args.priority is not None:
|
||||
record.priority = parsed_args.priority
|
||||
|
||||
if parsed_args.description:
|
||||
@ -157,7 +157,7 @@ class UpdateRecordCommand(base.UpdateCommand):
|
||||
|
||||
if parsed_args.no_priority:
|
||||
record.priority = None
|
||||
elif parsed_args.priority:
|
||||
elif parsed_args.priority is not None:
|
||||
record.priority = parsed_args.priority
|
||||
|
||||
if parsed_args.no_description:
|
||||
|
@ -42,7 +42,7 @@
|
||||
"priority": {
|
||||
"type": ["integer", "null"],
|
||||
"description": "DNS Record Priority",
|
||||
"minimum": 1,
|
||||
"minimum": 0,
|
||||
"maximum": 65535
|
||||
},
|
||||
"ttl": {
|
||||
|
Loading…
Reference in New Issue
Block a user