Fix for some AW anime
This commit is contained in:
@@ -138,6 +138,10 @@ async def animeworld(id,client):
|
|||||||
showname = showname.replace(key, showname_replace[key])
|
showname = showname.replace(key, showname_replace[key])
|
||||||
if "Naruto:" in showname:
|
if "Naruto:" in showname:
|
||||||
showname = showname.replace(":", "")
|
showname = showname.replace(":", "")
|
||||||
|
if "’" in showname:
|
||||||
|
showname = showname.split("’")[0]
|
||||||
|
if ":" in showname:
|
||||||
|
showname = showname.split(":")[0]
|
||||||
final_urls = await search(showname,date,ismovie,episode,client)
|
final_urls = await search(showname,date,ismovie,episode,client)
|
||||||
return final_urls
|
return final_urls
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
@@ -147,7 +151,7 @@ async def animeworld(id,client):
|
|||||||
async def test_animeworld():
|
async def test_animeworld():
|
||||||
async with AsyncSession() as client:
|
async with AsyncSession() as client:
|
||||||
# Replace with actual id, for example 'anime_id:episode' format
|
# Replace with actual id, for example 'anime_id:episode' format
|
||||||
test_id = "kitsu:48671:1" # This is an example ID format
|
test_id = "kitsu:508:2" # This is an example ID format
|
||||||
results = await animeworld(test_id, client)
|
results = await animeworld(test_id, client)
|
||||||
print(results)
|
print(results)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user