Show Light Novel for Anilist
This commit is contained in:
parent
54dce31d49
commit
935d2cd8ce
|
@ -51,7 +51,6 @@ FORMAT_NAMES = {
|
||||||
"ONA": "ONA",
|
"ONA": "ONA",
|
||||||
"MUSIC": "Music",
|
"MUSIC": "Music",
|
||||||
"MANGA": "Manga",
|
"MANGA": "Manga",
|
||||||
"NOVEL": "Novel",
|
|
||||||
"ONE_SHOT": "One Shot"
|
"ONE_SHOT": "One Shot"
|
||||||
}
|
}
|
||||||
CHARACTER_QUERY = '''query ($id: Int, $search: String) {
|
CHARACTER_QUERY = '''query ($id: Int, $search: String) {
|
||||||
|
@ -75,6 +74,9 @@ async def generate_media(anilist):
|
||||||
title_romaji = anilist['title']['romaji']
|
title_romaji = anilist['title']['romaji']
|
||||||
title_english = anilist['title']['english']
|
title_english = anilist['title']['english']
|
||||||
title_native = anilist['title']['native']
|
title_native = anilist['title']['native']
|
||||||
|
if anilist['format'] == 'NOVEL':
|
||||||
|
type = 'Light Novel'
|
||||||
|
else:
|
||||||
type = anilist['type'].capitalize()
|
type = anilist['type'].capitalize()
|
||||||
format = anilist['format']
|
format = anilist['format']
|
||||||
format = FORMAT_NAMES.get(format, format)
|
format = FORMAT_NAMES.get(format, format)
|
||||||
|
|
Loading…
Reference in New Issue