Small edit to net-pos.py

This commit is contained in:
Jeroen Oudshoorn
2024-01-22 12:35:21 +01:00
parent 9a9ee70a78
commit 4fe603bf5e

View File

@ -24,6 +24,7 @@ class NetPos(plugins.Plugin):
self.skip = list() self.skip = list()
self.ready = False self.ready = False
self.lock = threading.Lock() self.lock = threading.Lock()
self.options = dict()
def on_loaded(self): def on_loaded(self):
if 'api_key' not in self.options or ('api_key' in self.options and not self.options['api_key']): if 'api_key' not in self.options or ('api_key' in self.options and not self.options['api_key']):
@ -116,6 +117,7 @@ class NetPos(plugins.Plugin):
except OSError as os_e: except OSError as os_e:
logging.error("NET-POS: %s", os_e) logging.error("NET-POS: %s", os_e)
def _get_netpos(self, agent): def _get_netpos(self, agent):
aps = agent.get_access_points() aps = agent.get_access_points()
netpos = dict() netpos = dict()