Re-add forgotten seriesInfo.json to new downloads
This commit is contained in:
parent
8f5dd5aab5
commit
425cf7e0d6
@ -33,6 +33,7 @@ public class DownloadNewChapters : Job
|
||||
|
||||
protected override IEnumerable<Job> ExecuteReturnSubTasksInternal()
|
||||
{
|
||||
manga.SaveSeriesInfoJson(settings.downloadLocation);
|
||||
Chapter[] chapters = mangaConnector.GetNewChapters(manga, this.translatedLanguage);
|
||||
this.progressToken.increments = chapters.Length;
|
||||
List<Job> jobs = new();
|
||||
|
@ -105,7 +105,7 @@ public struct Manga
|
||||
/// <returns>Serialized JSON String for series.json</returns>
|
||||
private string GetSeriesInfoJson()
|
||||
{
|
||||
SeriesInfo si = new (new Metadata(this.sortName, this.year.ToString() ?? string.Empty, this.status, this.description ?? ""));
|
||||
SeriesInfo si = new (new Metadata(this));
|
||||
return System.Text.Json.JsonSerializer.Serialize(si);
|
||||
}
|
||||
|
||||
@ -151,6 +151,11 @@ public struct Manga
|
||||
"droppato"
|
||||
};
|
||||
|
||||
public Metadata(Manga manga) : this(manga.sortName, manga.year.ToString() ?? string.Empty, manga.status, manga.description ?? "")
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public Metadata(string name, string year, string status, string description_text)
|
||||
{
|
||||
this.name = name;
|
||||
|
Loading…
Reference in New Issue
Block a user