Fix embed sorting & inlining

pull/102/head
Stijn De Clercq 2021-11-29 22:06:02 +01:00
parent 81bdde9632
commit dd60840576
1 changed files with 2 additions and 2 deletions

View File

@ -52,7 +52,7 @@ class Deadlines:
return embed return embed
courses: Dict courses: Dict
for year, courses in self.data.items(): for year, courses in sorted(self.data.items(), key=lambda x: x[0]):
content = [] content = []
deadlines: Dict[str, int] deadlines: Dict[str, int]
@ -63,6 +63,6 @@ class Deadlines:
content.sort(key=lambda x: x.t) content.sort(key=lambda x: x.t)
content = map(lambda x: str(x), content) content = map(lambda x: str(x), content)
embed.add_field(name=get_edu_year(int(year)), value="\n".join(content)) embed.add_field(name=get_edu_year(int(year)), value="\n".join(content), inline=False)
return embed return embed