Compare commits
No commits in common. "5458c43f21c425c6528a7008f9be95ec26cd3cb9" and "88876fb8f4a67590ff3b1667fec49a0c10be3e4a" have entirely different histories.
5458c43f21
...
88876fb8f4
@ -1,5 +1,4 @@
|
|||||||
using System.Net;
|
using System.Net.Http.Headers;
|
||||||
using System.Net.Http.Headers;
|
|
||||||
using HtmlAgilityPack;
|
using HtmlAgilityPack;
|
||||||
|
|
||||||
namespace Tranga.MangaConnectors;
|
namespace Tranga.MangaConnectors;
|
||||||
@ -33,16 +32,8 @@ internal class HttpDownloadClient : DownloadClient
|
|||||||
if (referrer is not null)
|
if (referrer is not null)
|
||||||
requestMessage.Headers.Referrer = new Uri(referrer);
|
requestMessage.Headers.Referrer = new Uri(referrer);
|
||||||
//Log($"Requesting {requestType} {url}");
|
//Log($"Requesting {requestType} {url}");
|
||||||
try
|
|
||||||
{
|
|
||||||
response = Client.Send(requestMessage);
|
response = Client.Send(requestMessage);
|
||||||
}
|
}
|
||||||
catch (TaskCanceledException e)
|
|
||||||
{
|
|
||||||
Log($"Request timed out.\n\r{e}");
|
|
||||||
return new RequestResult(HttpStatusCode.RequestTimeout, null, Stream.Null);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!response.IsSuccessStatusCode)
|
if (!response.IsSuccessStatusCode)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user