Fix local variable 'version_added' referenced before assignment. Fixes #15
This commit is contained in:
parent
f0e769e125
commit
ab74928259
1 changed files with 2 additions and 1 deletions
|
@ -337,8 +337,9 @@ class ModuleValidator(Validator):
|
|||
try:
|
||||
version_added = StrictVersion(str(doc.get('version_added', '0.0')))
|
||||
except ValueError:
|
||||
version_added = doc.get('version_added', '0.0')
|
||||
self.errors.append('version_added is not a valid version '
|
||||
'number: %s' % version_added)
|
||||
'number: %r' % version_added)
|
||||
return
|
||||
|
||||
strict_ansible_version = StrictVersion(ansible_version)
|
||||
|
|
Loading…
Reference in a new issue