From 7b6253de0f896bc99f909828718541fbd3613273 Mon Sep 17 00:00:00 2001 From: glax Date: Mon, 22 May 2023 21:37:30 +0200 Subject: [PATCH] Create Publication Folder at start of DownloadNewChapters --- Tranga/TaskExecutor.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Tranga/TaskExecutor.cs b/Tranga/TaskExecutor.cs index 8f2c0d0..0993bac 100644 --- a/Tranga/TaskExecutor.cs +++ b/Tranga/TaskExecutor.cs @@ -92,13 +92,13 @@ public static class TaskExecutor /// private static void DownloadNewChapters(Connector connector, Publication publication, string language, ref Dictionary> chapterCollection) { - List newChapters = UpdateChapters(connector, publication, language, ref chapterCollection); - connector.DownloadCover(publication); - - //Check if Publication already has a Folder and a series.json + //Check if Publication already has a Folder string publicationFolder = Path.Join(connector.downloadLocation, publication.folderName); if(!Directory.Exists(publicationFolder)) Directory.CreateDirectory(publicationFolder); + List newChapters = UpdateChapters(connector, publication, language, ref chapterCollection); + + connector.DownloadCover(publication); string seriesInfoPath = Path.Join(publicationFolder, "series.json"); if(!File.Exists(seriesInfoPath))