Fix possible nullreference
This commit is contained in:
parent
3cea5fb431
commit
fec5ad664c
@ -181,6 +181,8 @@ public class Manganato : MangaConnector
|
|||||||
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
|
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
|
||||||
return requestResult.statusCode;
|
return requestResult.statusCode;
|
||||||
|
|
||||||
|
if (requestResult.htmlDocument is null)
|
||||||
|
return HttpStatusCode.InternalServerError;
|
||||||
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
|
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
|
||||||
|
|
||||||
string comicInfoPath = Path.GetTempFileName();
|
string comicInfoPath = Path.GetTempFileName();
|
||||||
|
@ -159,6 +159,8 @@ public class Mangaworld: MangaConnector
|
|||||||
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
|
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
|
||||||
return requestResult.statusCode;
|
return requestResult.statusCode;
|
||||||
|
|
||||||
|
if (requestResult.htmlDocument is null)
|
||||||
|
return HttpStatusCode.InternalServerError;
|
||||||
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
|
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
|
||||||
|
|
||||||
string comicInfoPath = Path.GetTempFileName();
|
string comicInfoPath = Path.GetTempFileName();
|
||||||
|
Loading…
Reference in New Issue
Block a user