fix(speedtest): just show the speedtest.net image
This commit is contained in:
parent
94b692a705
commit
9103d64fbc
1 changed files with 1 additions and 8 deletions
|
@ -62,17 +62,10 @@ class Speedtest(commands.Cog):
|
|||
await msg.edit(embed=discord.Embed(description=f"An error occurred! {speedtest}", color=discord.Colour.red()))
|
||||
return
|
||||
embed = discord.Embed(title="Speedtest Results", url=speedtest.result.url, color=await ctx.embed_color())
|
||||
embed.add_field(name="Bandwidth", value=f"{speedtest.download.mbps:,.2f} Mbps down, {speedtest.upload.mbps:,.2f} Mbps up")
|
||||
embed.add_field(name="Ping", value=f"Base: {round(speedtest.ping.latency)} ms \nDownload: {round(speedtest.download.latency.iqm)} ms \nUpload: {round(speedtest.upload.latency.iqm)} ms")
|
||||
embed.set_image(url=speedtest.result.image)
|
||||
await msg.edit(embed=embed)
|
||||
else:
|
||||
if not isinstance(speedtest, sp):
|
||||
await msg.edit(content=f"An error occurred! \n`{speedtest}`")
|
||||
return
|
||||
await msg.edit(content=f"**Speedtest Results**\n"
|
||||
f"**Bandwidth**: {speedtest.download.mbps:,.2f} Mbps down ({speedtest.download.bandwidth}), {speedtest.download.mbps:,.2f} Mbps up\n"
|
||||
f"**Ping**: Base: {round(speedtest.ping.latency)} ms\n"
|
||||
f"Download: {round(speedtest.download.latency.iqm)} ms\n"
|
||||
f"Upload: {round(speedtest.upload.latency.iqm)} ms\n"
|
||||
f"**Image**: {speedtest.result.image}")
|
||||
await msg.edit(content=f"**[Result]({speedtest.result.url})**")
|
||||
|
|
Loading…
Reference in a new issue