endswith supports tuples, nicer

This commit is contained in:
Brian Coca 2017-07-24 16:48:47 -04:00
parent 8387b839d8
commit 96d577c4c9

View file

@ -161,7 +161,7 @@ class InventoryModule(BaseInventoryPlugin):
valid = False
if super(InventoryModule, self).verify_file(path):
if path.endswith('.vbox.yaml') or path.endswith('.vbox.yml'):
if path.endswith(('.vbox.yaml', '.vbox.yml')):
valid = True
return valid