Skip to content

Commit

Permalink
FC announcement fix
Browse files Browse the repository at this point in the history
  • Loading branch information
lekeno committed Oct 2, 2023
1 parent 463b106 commit 5f41513
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions edr/edrdiscord.py
Original file line number Diff line number Diff line change
Expand Up @@ -483,7 +483,7 @@ def __create_discord_fc_jump_psa(self, jump_info):
departureTime.from_js_epoch(jump_info["at"])
lockdownTime = EDTime()
lockdownTime.from_js_epoch(jump_info["lockdown"])
de.description = _("```From : {}\nTo : {}\nBody: {}\nTime(UTC): {}```").format(jump_info["from"], jump_info["to"], departureTime.as_hhmmss())
de.description = _("```From : {}\nTo : {}\nBody : {}\nTime(UTC): {}```").format(jump_info["from"], jump_info["to"], jump_info["body"], departureTime.as_hhmmss())
de.author = {
"name": "{} | {}".format(jump_info["name"], jump_info["callsign"]),
"url": cfg["url"],
Expand All @@ -500,7 +500,7 @@ def __create_discord_fc_jump_psa(self, jump_info):
}

if sender_profile:
df = EDRDiscordField(_(u"Landing"), _("```Access : {}\nNotorious: {}\nLockdown(UTC): {}```").format(self.__readable_fc_docking(jump_info["access"]), self.__readable_fc_notorious(jump_info["allow_notorious"], lockdownTime.as_hhmmss())), True)
df = EDRDiscordField(_(u"Landing"), _("```Access : {}\nNotorious: {}\nLockdown(UTC): {}```").format(self.__readable_fc_docking(jump_info["access"]), self.__readable_fc_notorious(jump_info["allow_notorious"]), lockdownTime.as_hhmmss()), True)
de.fields.append(df)

dm.add_embed(de)
Expand Down Expand Up @@ -612,7 +612,6 @@ def __process_outgoing(self, entry):
def __default_cfg(self, cmdr_name):
random.seed(len(cmdr_name))
style = random.choice(["identicon", "retro", "monsterid", "wavatar", "robohash"])
random.seed()
gravatar_url = u"https://www.gravatar.com/avatar/{}?d={}&f=y".format(md5(cmdr_name.encode('utf-8')).hexdigest(), style)
default_cfg = {
"name": cmdr_name,
Expand Down

0 comments on commit 5f41513

Please sign in to comment.