mirror of
https://github.com/Jackett/Jackett
synced 2025-03-09 13:52:03 +00:00
hdbits: update halfleech rules for TV
This commit is contained in:
parent
9b5357c5c2
commit
5a4bbc36ab
1 changed files with 5 additions and 9 deletions
|
@ -227,7 +227,6 @@ namespace Jackett.Common.Indexers
|
|||
|
||||
private static double GetDownloadFactor(JObject r)
|
||||
{
|
||||
var halfLeechMediums = new[] { 1, 5, 4 };
|
||||
// 100% Neutral Leech: all XXX content.
|
||||
if ((int)r["type_category"] == 7)
|
||||
{
|
||||
|
@ -240,18 +239,14 @@ namespace Jackett.Common.Indexers
|
|||
return 0;
|
||||
}
|
||||
|
||||
// 50% Free Leech: all full discs, remuxes, caps and all internal encodes.
|
||||
if (halfLeechMediums.Contains((int)r["type_medium"]) || (int)r["type_origin"] == 1)
|
||||
var halfLeechMediums = new[] { 1, 5, 4 };
|
||||
|
||||
// 50% Free Leech: all full discs, remuxes, captures and all internal encodes, also all TV and Documentary content.
|
||||
if (halfLeechMediums.Contains((int)r["type_medium"]) || (int)r["type_origin"] == 1 || (int)r["type_category"] == 2 || (int)r["type_category"] == 3)
|
||||
{
|
||||
return 0.5;
|
||||
}
|
||||
|
||||
// 25% Free Leech: all TV content that is not an internal encode.
|
||||
if ((int)r["type_category"] == 2 && (int)r["type_origin"] != 1)
|
||||
{
|
||||
return 0.75;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
@ -267,6 +262,7 @@ namespace Jackett.Common.Indexers
|
|||
{"Accept", "application/json"},
|
||||
{"Content-Type", "application/json"}
|
||||
}, requestData.ToString(), false);
|
||||
|
||||
CheckSiteDown(response);
|
||||
|
||||
JObject json;
|
||||
|
|
Loading…
Add table
Reference in a new issue