mirror of
https://github.com/C9Glax/tranga.git
synced 2025-05-22 06:03:01 +02:00
Fix Manga-Chapter loading
This commit is contained in:
parent
3a3306240f
commit
d6e945741a
@ -37,6 +37,7 @@ public class DownloadAvailableChaptersJob : Job
|
||||
protected override IEnumerable<Job> RunInternal(PgsqlContext context)
|
||||
{
|
||||
context.Attach(Manga);
|
||||
context.Entry(Manga).Collection<Chapter>(m => m.Chapters).Load();
|
||||
return Manga.Chapters.Select(chapter => new DownloadSingleChapterJob(chapter, this));
|
||||
}
|
||||
}
|
@ -37,6 +37,7 @@ public class UpdateChaptersDownloadedJob : Job
|
||||
protected override IEnumerable<Job> RunInternal(PgsqlContext context)
|
||||
{
|
||||
context.Attach(Manga);
|
||||
context.Entry(Manga).Collection<Chapter>(m => m.Chapters).Load();
|
||||
return Manga.Chapters.Select(c => new UpdateSingleChapterDownloadedJob(c, this));
|
||||
}
|
||||
}
|
@ -39,7 +39,6 @@ public class UpdateSingleChapterDownloadedJob : Job
|
||||
{
|
||||
context.Attach(Chapter);
|
||||
Chapter.Downloaded = Chapter.CheckDownloaded();
|
||||
context.SaveChanges();
|
||||
|
||||
try
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user