mirror of
https://github.com/Jackett/Jackett.git
synced 2025-09-17 17:34:09 +02:00
chore: apply dotnet format (#13880)
This commit is contained in:
@@ -267,8 +267,10 @@ namespace Jackett.Common.Indexers
|
|||||||
|
|
||||||
if (!string.IsNullOrEmpty(configData.UserAgent.Value))
|
if (!string.IsNullOrEmpty(configData.UserAgent.Value))
|
||||||
{
|
{
|
||||||
headers = new Dictionary<string, string>();
|
headers = new Dictionary<string, string>
|
||||||
headers.Add("User-Agent", configData.UserAgent.Value);
|
{
|
||||||
|
{ "User-Agent", configData.UserAgent.Value }
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (var cat in MapTorznabCapsToTrackers(query))
|
foreach (var cat in MapTorznabCapsToTrackers(query))
|
||||||
|
@@ -248,8 +248,10 @@ namespace Jackett.Common.Indexers
|
|||||||
|
|
||||||
if (!string.IsNullOrEmpty(configData.UserAgent.Value))
|
if (!string.IsNullOrEmpty(configData.UserAgent.Value))
|
||||||
{
|
{
|
||||||
headers = new Dictionary<string, string>();
|
headers = new Dictionary<string, string>
|
||||||
headers.Add("User-Agent", configData.UserAgent.Value);
|
{
|
||||||
|
{ "User-Agent", configData.UserAgent.Value }
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
if (query.IsImdbQuery)
|
if (query.IsImdbQuery)
|
||||||
|
@@ -225,16 +225,14 @@ namespace Jackett.Common.Indexers
|
|||||||
var release = new ReleaseInfo
|
var release = new ReleaseInfo
|
||||||
{
|
{
|
||||||
MinimumRatio = 1,
|
MinimumRatio = 1,
|
||||||
MinimumSeedTime = 0
|
MinimumSeedTime = 0,
|
||||||
|
// Get Category
|
||||||
|
Category = MapTrackerCatToNewznab(torrent[7].ToString()),
|
||||||
|
// Title, description and details link
|
||||||
|
Title = torrent[3].ToString(),
|
||||||
|
Description = torrent[6].ToString(),
|
||||||
|
Details = new Uri($"{SiteLink}index.html#torrent/{torrent[0]}")
|
||||||
};
|
};
|
||||||
|
|
||||||
// Get Category
|
|
||||||
release.Category = MapTrackerCatToNewznab(torrent[7].ToString());
|
|
||||||
|
|
||||||
// Title, description and details link
|
|
||||||
release.Title = torrent[3].ToString();
|
|
||||||
release.Description = torrent[6].ToString();
|
|
||||||
release.Details = new Uri($"{SiteLink}index.html#torrent/{torrent[0]}");
|
|
||||||
release.Guid = release.Details;
|
release.Guid = release.Details;
|
||||||
|
|
||||||
// Date of torrent creation
|
// Date of torrent creation
|
||||||
|
@@ -146,10 +146,12 @@ namespace Jackett.Common.Indexers
|
|||||||
var releases = new List<ReleaseInfo>();
|
var releases = new List<ReleaseInfo>();
|
||||||
|
|
||||||
var searchString = query.GetQueryString();
|
var searchString = query.GetQueryString();
|
||||||
var queryCollection = new NameValueCollection { { "apikey", ConfigData.Key.Value } };
|
var queryCollection = new NameValueCollection
|
||||||
|
{
|
||||||
queryCollection.Add("limit", "50"); // Default 30
|
{ "apikey", ConfigData.Key.Value },
|
||||||
queryCollection.Add("ponly", ProductsOnly ? "true" : "false");
|
{ "limit", "50" }, // Default 30
|
||||||
|
{ "ponly", ProductsOnly ? "true" : "false" }
|
||||||
|
};
|
||||||
foreach (var releaseType in ReleaseType)
|
foreach (var releaseType in ReleaseType)
|
||||||
{
|
{
|
||||||
queryCollection.Add("release_type", releaseType);
|
queryCollection.Add("release_type", releaseType);
|
||||||
|
@@ -204,9 +204,7 @@ namespace Jackett.Common.Utils.Clients
|
|||||||
isBinary = true;
|
isBinary = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
logger.Debug($@"WebClient({ClientType}): Returning {result.Status} => {
|
logger.Debug($@"WebClient({ClientType}): Returning {result.Status} => {(result.IsRedirect ? result.RedirectingTo + " " : "")}{bodySize} bytes{body}");
|
||||||
(result.IsRedirect ? result.RedirectingTo + " " : "")
|
|
||||||
}{bodySize} bytes{body}");
|
|
||||||
if (isBinary)
|
if (isBinary)
|
||||||
{
|
{
|
||||||
// show the first 20 bytes in a hex dump
|
// show the first 20 bytes in a hex dump
|
||||||
|
@@ -723,7 +723,7 @@ namespace Jackett.Updater
|
|||||||
startInfo.CreateNoWindow = true;
|
startInfo.CreateNoWindow = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
logger.Info($"Starting Jackett: \"{startInfo.FileName }\" {startInfo.Arguments}");
|
logger.Info($"Starting Jackett: \"{startInfo.FileName}\" {startInfo.Arguments}");
|
||||||
Process.Start(startInfo);
|
Process.Start(startInfo);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user