Moved notification to DownloadChapterTask, sends when parentTask exists.

This commit is contained in:
glax 2023-06-19 22:34:34 +02:00
parent 6cdccdf66b
commit edc24fff5b

View File

@ -30,6 +30,9 @@ public class DownloadChapterTask : TrangaTask
if(this.parentTask is not null)
this.parentTask.state = ExecutionState.Waiting;
taskManager.DeleteTask(this);
if(parentTask is not null)
foreach(NotificationManager nm in taskManager.settings.notificationManagers)
nm.SendNotification("New Chapter downloaded", $"{this.publication.sortName} {this.chapter.chapterNumber} {this.chapter.name}");
}
public override string ToString()