Skip to content

Commit

Permalink
fix: revert IMDb metadata bug
Browse files Browse the repository at this point in the history
  • Loading branch information
g0ldyy authored Jul 24, 2024
1 parent 49d8ee7 commit 595c2c0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion comet/api/stream.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ async def stream(request: Request, b64config: str, type: str, id: str):
f"https://v3.sg.media-imdb.com/suggestion/a/{id}.json"
)
metadata = await get_metadata.json()
name = metadata["d"][0]["l"]
name = metadata["d"][0 if len(metadata["d"]) == 1 else 1]["l"]
except Exception as e:
logger.warning(f"Exception while getting metadata for {id}: {e}")

Expand Down

0 comments on commit 595c2c0

Please sign in to comment.