wow you can't even have a backslash in an fstring

This commit is contained in:
blank X 2021-03-28 18:25:31 +07:00
parent fe64b38339
commit 009342225c
Signed by: blankie
GPG Key ID: CC15FC822C7F61F5
1 changed files with 5 additions and 1 deletions

View File

@ -163,7 +163,11 @@ async def generate_character(anilist):
if title_alternative: if title_alternative:
text += f'\n<b>Synonyms:</b> {title_alternative}' text += f'\n<b>Synonyms:</b> {title_alternative}'
if media: if media:
text += f'\n<b>Featured In:</b>{" " if len(media) == 1 else "\n"}' text += '\n<b>Featured In:</b>'
if len(media) == 1:
text += ' '
else:
text += '\n'
to_add = [] to_add = []
for i in media: for i in media:
atext = f'<a href="{i["siteUrl"]}">{i["title"]["romaji"]}</a>' atext = f'<a href="{i["siteUrl"]}">{i["title"]["romaji"]}</a>'