Fixed exception handling a little more

This commit is contained in:
Mark J. Horninger 2024-03-10 22:19:10 -04:00
parent 83bc0a0071
commit 6691863466
1 changed files with 1 additions and 1 deletions

View File

@ -151,7 +151,7 @@ class InventoryModule(BaseInventoryPlugin, Constructable, Cacheable):
"""Get the inventory from the Netbird API"""
try:
self.peers = self.client.ListPeers()
except Exception as e:
except ConnectionRefusedError|ConnectionError as e:
raise AnsibleError from e
def _filter_by_config(self):