mirror of
https://github.com/Jackett/Jackett
synced 2025-03-06 11:48:49 +00:00
beyond-hd-api: fix search by imdbid without removing leading zeros
This commit is contained in:
parent
0bc453be56
commit
77aada87d1
1 changed files with 8 additions and 4 deletions
|
@ -124,11 +124,15 @@ namespace Jackett.Common.Indexers
|
|||
else if (query.IsMovieSearch)
|
||||
postData.Add(BHDParams.categories, "Movies");
|
||||
|
||||
var imdbId = ParseUtil.GetImdbId(query.ImdbID);
|
||||
if (imdbId != null)
|
||||
postData.Add(BHDParams.imdb_id, imdbId.ToString());
|
||||
if (query.IsImdbQuery)
|
||||
{
|
||||
postData.Add(BHDParams.imdb_id, query.ImdbIDShort);
|
||||
}
|
||||
|
||||
if (query.IsTmdbQuery)
|
||||
postData.Add(BHDParams.tmdb_id, query.TmdbID.Value.ToString());
|
||||
{
|
||||
postData.Add(BHDParams.tmdb_id, query.TmdbID.ToString());
|
||||
}
|
||||
|
||||
var bhdResponse = await GetBHDResponse(apiUrl, postData);
|
||||
var releaseInfos = bhdResponse.results.Select(mapToReleaseInfo);
|
||||
|
|
Loading…
Add table
Reference in a new issue