chore: fetch season 2 information

This commit is contained in:
insert 2025-06-23 06:55:43 -04:00
parent 0ad64bc326
commit 58c35d349e
Signed by: insert
GPG key ID: A70775C389ACF105

View file

@ -216,7 +216,7 @@ class TeamView(nextcord.ui.View):
embed = ogmsg[0]
teamid = embed.footer.text
data = requests.get(f"https://mmolb.com/api/team/{teamid}").json()
history = requests.get(f"https://freecashe.ws/api/games?team={teamid}&season=1").json()["items"]
history = requests.get(f"https://freecashe.ws/api/games?team={teamid}&season=2").json()["items"]
color = tuple(int(data["Color"][i:i+2], 16) for i in (0, 2, 4))
embed = nextcord.Embed(title=f"Last ten games for the {data["Location"]} {data["Name"]} {data["Emoji"]}", colour = nextcord.Color.from_rgb(color[0], color[1], color[2]))
embed.set_footer(text=teamid)
@ -319,7 +319,7 @@ class team(commands.Cog):
await interaction.response.defer()
teamid = teams_dict[team]
data = requests.get(f"https://mmolb.com/api/team/{teamid}").json()
history = requests.get(f"https://freecashe.ws/api/games?team={teamid}&season=1").json()["items"]
history = requests.get(f"https://freecashe.ws/api/games?team={teamid}&season=2").json()["items"]
color = tuple(int(data["Color"][i:i+2], 16) for i in (0, 2, 4))
embed = nextcord.Embed(title=f"Last ten games for the {data["Location"]} {data["Name"]} {data["Emoji"]}", colour = nextcord.Color.from_rgb(color[0], color[1], color[2]))
embed.set_footer(text=teamid)