From bf592168c1ae69eece7198b42fec42ef2343810c Mon Sep 17 00:00:00 2001 From: alterNERDtive Date: Tue, 29 Sep 2020 11:09:13 +0200 Subject: [PATCH] explorationtools.py: fixed finding cmdr with hidden activity time --- explorationtools.py | 7 +++++-- pyEDSM | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/explorationtools.py b/explorationtools.py index 8194297..b20d3c4 100755 --- a/explorationtools.py +++ b/explorationtools.py @@ -32,8 +32,11 @@ def getCommanderProfileUrl(name, apikey): def getCommanderSystem(name, apikey): cmdr = Commander(name, apikey) - return "{} (last seen {})".format(cmdr.currentSystem, - when(cmdr.lastActivity)) + if cmdr.lastActivity is None: + return "{}".format(cmdr.currentSystem) + else: + return "{} (last seen {})".format(cmdr.currentSystem, + when(cmdr.lastActivity)) def when(date): diff = datetime.now() - date ret = "" diff --git a/pyEDSM b/pyEDSM index 36a660f..be921a4 160000 --- a/pyEDSM +++ b/pyEDSM @@ -1 +1 @@ -Subproject commit 36a660f240c7e57cf524fe9640d13e56c7e42e79 +Subproject commit be921a4f83a6b36155bca9814d9647ecae341f1d