From baf0a693967294f12175fad272c4c0cdb7d65882 Mon Sep 17 00:00:00 2001 From: alterNERDtive Date: Wed, 21 Oct 2020 03:37:41 +0200 Subject: [PATCH] fixed finding cmdr with hidden system/coords --- explorationtools.py | 11 +++++++---- pyEDSM | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/explorationtools.py b/explorationtools.py index b20d3c4..e2cb0b9 100755 --- a/explorationtools.py +++ b/explorationtools.py @@ -22,10 +22,13 @@ def distanceBetween(system1, system2, roundTo=2): def getCommanderPosition(name, apikey): coords = Commander(name, apikey).currentPosition - ret = "" - for k in coords: - ret += "{}: {}, ".format(k, coords[k]) - return ret[:-2] + ret = "hidden" + if coords: + ret = "" + for k in coords: + ret += "{}: {}, ".format(k, coords[k]) + ret = ret[:-2] + return ret def getCommanderProfileUrl(name, apikey): return Commander(name, apikey).profileUrl diff --git a/pyEDSM b/pyEDSM index be921a4..7b6e31e 160000 --- a/pyEDSM +++ b/pyEDSM @@ -1 +1 @@ -Subproject commit be921a4f83a6b36155bca9814d9647ecae341f1d +Subproject commit 7b6e31e51db59924bb138661d0097321ea2c16c8