Forget about wrapping the error

This commit is contained in:
Mark J. Horninger 2024-03-10 22:35:31 -04:00
parent 7610c9b8ce
commit d295a97588
1 changed files with 2 additions and 2 deletions

View File

@ -151,8 +151,8 @@ class InventoryModule(BaseInventoryPlugin, Constructable, Cacheable):
"""Get the inventory from the Netbird API"""
try:
self.peers = self.client.ListPeers()
except Exception as e:
raise AnsibleError(f"Could not retrieve the Netbird inventory: {e.message}")
except:
raise AnsibleError(f"Could not retrieve the Netbird inventory. Check the API Key and URL.")
def _filter_by_config(self):
"""Filter peers by user specified configuration."""