From fc3d8d1aec83315b2d58ade10392949ab3e322d5 Mon Sep 17 00:00:00 2001 From: kaso17 Date: Mon, 30 Jul 2018 13:16:13 +0200 Subject: [PATCH] Gazelle: fix free leech token usage for large torrents --- src/Jackett.Common/Indexers/Abstract/GazelleTracker.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/Jackett.Common/Indexers/Abstract/GazelleTracker.cs b/src/Jackett.Common/Indexers/Abstract/GazelleTracker.cs index ed2e169c4..66f26096d 100644 --- a/src/Jackett.Common/Indexers/Abstract/GazelleTracker.cs +++ b/src/Jackett.Common/Indexers/Abstract/GazelleTracker.cs @@ -318,7 +318,7 @@ namespace Jackett.Common.Indexers.Abstract { var content = await base.Download(link); - // Check if we're out of FL tokens + // Check if we're out of FL tokens/torrent is to large // most gazelle trackers will simply return the torrent anyway but e.g. redacted will return an error var requestLink = link.ToString(); if (content.Length >= 1 @@ -326,7 +326,8 @@ namespace Jackett.Common.Indexers.Abstract && requestLink.Contains("usetoken=1")) { var html = Encoding.GetString(content); - if (html.Contains("You do not have any freeleech tokens left.")) + if (html.Contains("You do not have any freeleech tokens left.") + || html.Contains("This torrent is too large.")) { // download again with usetoken=0 var requestLinkNew = requestLink.Replace("usetoken=1", "usetoken=0");