Merge "Replace assert with condition"
This commit is contained in:
commit
7d50e5fc9a
@ -1031,9 +1031,7 @@ class UnsetImage(command.Command):
|
|||||||
|
|
||||||
if parsed_args.properties:
|
if parsed_args.properties:
|
||||||
for k in parsed_args.properties:
|
for k in parsed_args.properties:
|
||||||
try:
|
if k not in image:
|
||||||
assert(k in image.keys())
|
|
||||||
except AssertionError:
|
|
||||||
LOG.error(_("property unset failed, '%s' is a "
|
LOG.error(_("property unset failed, '%s' is a "
|
||||||
"nonexistent property "), k)
|
"nonexistent property "), k)
|
||||||
propret += 1
|
propret += 1
|
||||||
|
Loading…
Reference in New Issue
Block a user