From 96d577c4c9a0f822331e924c7c434c1dacb4f933 Mon Sep 17 00:00:00 2001 From: Brian Coca Date: Mon, 24 Jul 2017 16:48:47 -0400 Subject: [PATCH] endswith supports tuples, nicer --- lib/ansible/plugins/inventory/virtualbox.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/plugins/inventory/virtualbox.py b/lib/ansible/plugins/inventory/virtualbox.py index b25749610a..0dab7c4253 100755 --- a/lib/ansible/plugins/inventory/virtualbox.py +++ b/lib/ansible/plugins/inventory/virtualbox.py @@ -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