Skip to content

Commit

Permalink
[Starboard] Fix missing context URL's
Browse files Browse the repository at this point in the history
  • Loading branch information
TrustyJAID committed May 9, 2023
1 parent 9e96261 commit d1d38d8
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions starboard/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,16 +112,16 @@ async def _build_embed(
)
except Exception:
pass
em.timestamp = message.created_at
jump_link = _("\n\n{link}").format(link=message.jump_url)
if em.description:
with_context = f"{em.description}{jump_link}"
if len(with_context) > 2048:
em.add_field(name=_("Context"), value=jump_link)
else:
em.description = with_context
em.timestamp = message.created_at
jump_link = _("\n\n{link}").format(link=message.jump_url)
if em.description:
with_context = f"{em.description}{jump_link}"
if len(with_context) > 2048:
em.add_field(name=_("Context"), value=jump_link)
else:
em.description = jump_link
em.description = with_context
else:
em.description = jump_link
em.set_footer(text=f"{channel.guild.name} | {channel.name}")
if message.attachments:
for attachment in message.attachments:
Expand Down

0 comments on commit d1d38d8

Please sign in to comment.