Skip to content

Commit

Permalink
Merge tag 'v0.16.2240'
Browse files Browse the repository at this point in the history
  • Loading branch information
abeloin committed Nov 26, 2020
2 parents f4f1458 + 4967fe4 commit e7fc137
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/Jackett.Common/Definitions/divteam.yml
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ search:
# does not support imdbid search and does not supply imdb link in results.

rows:
selector: table.table.table-bordered > tbody > tr:has(a[href^="download.php?id="]):not(:has(td[style*="background-color"]))
selector: table.table.table-bordered > tbody > tr:has(a[href^="download.php?id="])

fields:
download:
Expand Down
7 changes: 7 additions & 0 deletions src/Jackett.Common/Indexers/TorrentLeech.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using NLog;
using static Jackett.Common.Models.IndexerConfig.ConfigurationData;

namespace Jackett.Common.Indexers
{
Expand Down Expand Up @@ -64,6 +65,8 @@ public TorrentLeech(IIndexerConfigurationService configService, Utils.Clients.We
Language = "en-us";
Type = "private";

configData.AddDynamic("freeleech", new BoolItem { Name = "Search freeleech only", Value = false });

AddCategoryMapping(1, TorznabCatType.Movies, "Movies");
AddCategoryMapping(8, TorznabCatType.MoviesSD, "Movies Cam");
AddCategoryMapping(9, TorznabCatType.MoviesSD, "Movies TS/TC");
Expand Down Expand Up @@ -151,6 +154,10 @@ protected override async Task<IEnumerable<ReleaseInfo>> PerformQuery(TorznabQuer
searchString = Regex.Replace(searchString, @"(^|\s)-", " ");

var searchUrl = SearchUrl;

if (((BoolItem) configData.GetDynamic("freeleech")).Value)
searchUrl += "facets/tags%3AFREELEECH/";

if (query.IsImdbQuery)
searchUrl += "imdbID/" + query.ImdbID + "/";
else if (!string.IsNullOrWhiteSpace(searchString))
Expand Down

0 comments on commit e7fc137

Please sign in to comment.