2
0

Fix possible nullreference

This commit is contained in:
glax 2023-09-13 23:02:36 +02:00
parent 3cea5fb431
commit fec5ad664c
2 changed files with 4 additions and 0 deletions

View File

@ -181,6 +181,8 @@ public class Manganato : MangaConnector
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
return requestResult.statusCode;
if (requestResult.htmlDocument is null)
return HttpStatusCode.InternalServerError;
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
string comicInfoPath = Path.GetTempFileName();

View File

@ -159,6 +159,8 @@ public class Mangaworld: MangaConnector
if ((int)requestResult.statusCode < 200 || (int)requestResult.statusCode >= 300)
return requestResult.statusCode;
if (requestResult.htmlDocument is null)
return HttpStatusCode.InternalServerError;
string[] imageUrls = ParseImageUrlsFromHtml(requestResult.htmlDocument);
string comicInfoPath = Path.GetTempFileName();