core: modified filters for selectors (#11918)

This commit is contained in:
seeyabye
2021-06-15 01:11:23 +09:00
committed by GitHub
parent 044cfa851c
commit 0b376faf2d
13 changed files with 51 additions and 50 deletions

View File

@@ -64,6 +64,7 @@ download:
filters:
- name: querystring
args: url
search:
paths:
- path: torrents

View File

@@ -1797,7 +1797,7 @@ namespace Jackett.Common.Indexers
href = downloadElement.TextContent;
}
href = applyFilters(href, Download.Filters, variables);
href = applyFilters(href, selector.Filters, variables);
var torrentLink = resolvePath(href, link);
if (torrentLink.Scheme != "magnet")
{

View File

@@ -168,7 +168,6 @@ namespace Jackett.Common.Models
public class downloadBlock
{
public List<downloadsField> Selectors { get; set; }
public List<filterBlock> Filters { get; set; }
public string Method { get; set; }
public requestBlock Before { get; set; }
}
@@ -177,5 +176,6 @@ namespace Jackett.Common.Models
{
public string Selector { get; set; }
public string Attribute { get; set; }
public List<filterBlock> Filters { get; set; }
}
}