mirror of
https://github.com/Prowlarr/Prowlarr
synced 2026-04-22 12:50:48 +02:00
New: (Indexer) Rutracker.org (#371)
* first attempt at sc definition * add dologin. seems to return html instead of json * barebones working setup * added category but errors on override * fixed and tested * guid fix * fixed bdmv and dvd releases to report in radarr accepted format * New: (Indexer) RuTracker * minor fixes * somewhat working rutracker org defintion with some filtering * filter russian letters option implemented * deal with subtitle languages * russian filtering pretty good now * removed sc from branch * rutracker handles series ok now * final touches to rutracker * tore out the captcha Co-authored-by: Qstick <qstick@gmail.com>
This commit is contained in:
parent
96afb7f327
commit
2c6680e4fa
3 changed files with 1765 additions and 3 deletions
|
|
@ -30,6 +30,7 @@ public HttpRequest(string url, HttpAccept httpAccept = null)
|
|||
public HttpUri Url { get; set; }
|
||||
public HttpMethod Method { get; set; }
|
||||
public HttpHeader Headers { get; set; }
|
||||
public Encoding Encoding { get; set; }
|
||||
public byte[] ContentData { get; set; }
|
||||
public string ContentSummary { get; set; }
|
||||
public bool SuppressHttpError { get; set; }
|
||||
|
|
@ -75,8 +76,15 @@ public void SetContent(byte[] data)
|
|||
|
||||
public void SetContent(string data)
|
||||
{
|
||||
var encoding = HttpHeader.GetEncodingFromContentType(Headers.ContentType);
|
||||
ContentData = encoding.GetBytes(data);
|
||||
if (Encoding != null)
|
||||
{
|
||||
ContentData = Encoding.GetBytes(data);
|
||||
}
|
||||
else
|
||||
{
|
||||
var encoding = HttpHeader.GetEncodingFromContentType(Headers.ContentType);
|
||||
ContentData = encoding.GetBytes(data);
|
||||
}
|
||||
}
|
||||
|
||||
public void AddBasicAuthentication(string username, string password)
|
||||
|
|
|
|||
|
|
@ -47,7 +47,14 @@ public string Content
|
|||
{
|
||||
if (_content == null)
|
||||
{
|
||||
_content = Headers.GetEncodingFromContentType().GetString(ResponseData);
|
||||
if (Request.Encoding != null)
|
||||
{
|
||||
_content = Request.Encoding.GetString(ResponseData);
|
||||
}
|
||||
else
|
||||
{
|
||||
_content = Headers.GetEncodingFromContentType().GetString(ResponseData);
|
||||
}
|
||||
}
|
||||
|
||||
return _content;
|
||||
|
|
|
|||
1747
src/NzbDrone.Core/Indexers/Definitions/RuTracker.cs
Normal file
1747
src/NzbDrone.Core/Indexers/Definitions/RuTracker.cs
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue