celiao / tmdbsimple

A wrapper for The Movie Database API v3.
GNU General Public License v3.0
578 stars 122 forks source link

Do not update `id` of a TV_Episode #2

Closed getzze closed 10 years ago

getzze commented 10 years ago

When looking for an episode, the syntax is : episode = tmdb.TV_Episodes(series_id, season, episode)

Then when looking at the informations, episode.info() is called. But after this method call, the id of the TV_Episodes class is updated to the id of the episode. Then the next call to episode.info() or any other method will fail because the url in the api will have the following form : '/3/tv//season//episode/' instead of '/3/tv//...' id should not be updated for an episode, or a distinction should be made between the episode id and the series id.

celiao commented 10 years ago

Excellent catch. The id in the URL is the series id, and the id field in the response is the episode id. TV_Episodes has been updated to address this distinction.