mirror of
https://github.com/Prowlarr/Prowlarr
synced 2025-12-06 08:34:28 +01:00
Revert "Improve error message on non-JSON responses for Nebulance"
This reverts commit 2c3621d25e.
This commit is contained in:
parent
b463a3f54b
commit
8ac68240ad
1 changed files with 2 additions and 7 deletions
|
|
@ -240,6 +240,8 @@ public NebulanceParser(NebulanceSettings settings)
|
|||
|
||||
public IList<ReleaseInfo> ParseResponse(IndexerResponse indexerResponse)
|
||||
{
|
||||
var torrentInfos = new List<ReleaseInfo>();
|
||||
|
||||
if (indexerResponse.HttpResponse.StatusCode != HttpStatusCode.OK)
|
||||
{
|
||||
STJson.TryDeserialize<JsonRpcResponse<NebulanceErrorResponse>>(indexerResponse.HttpResponse.Content, out var errorResponse);
|
||||
|
|
@ -247,13 +249,6 @@ public IList<ReleaseInfo> ParseResponse(IndexerResponse indexerResponse)
|
|||
throw new IndexerException(indexerResponse, "Unexpected response status '{0}' code from indexer request: {1}", indexerResponse.HttpResponse.StatusCode, errorResponse?.Result?.Error?.Message ?? "Check the logs for more information.");
|
||||
}
|
||||
|
||||
if (!indexerResponse.HttpResponse.Headers.ContentType.Contains(HttpAccept.Json.Value))
|
||||
{
|
||||
throw new IndexerException(indexerResponse, "Unexpected response header {0} from indexer request, expected {1}", indexerResponse.HttpResponse.Headers.ContentType, HttpAccept.Json.Value);
|
||||
}
|
||||
|
||||
var torrentInfos = new List<ReleaseInfo>();
|
||||
|
||||
JsonRpcResponse<NebulanceResponse> jsonResponse;
|
||||
|
||||
try
|
||||
|
|
|
|||
Loading…
Reference in a new issue