fix(hianime-provider): first split by ?

This commit is contained in:
Benexl
2025-08-12 12:30:31 +03:00
parent b91129c4a7
commit 8b123cdae2

View File

@@ -64,7 +64,8 @@ class HiAnime(BaseAnimeProvider):
"""
try:
# The numeric ID is the last part of the slug.
anime_id_numeric = params.id.split("-")[-1]
clean_id_slug = params.id.split("?")[0]
anime_id_numeric = clean_id_slug.split("-")[-1]
if not anime_id_numeric.isdigit():
raise ValueError("Could not extract numeric ID from anime slug.")