Re-add completed audiobooks to queue (#1219)

This commit is contained in:
Michael Bucari-Tovo
2025-05-06 15:43:58 -06:00
parent 5ab6c1fe70
commit 8aa157f2f6
4 changed files with 22 additions and 0 deletions

View File

@@ -92,6 +92,11 @@ namespace LibationWinForms.ProcessQueue
return true;
}
public bool RemoveCompleted(DataLayer.LibraryBook libraryBook)
=> Queue.FirstOrDefault(b => b?.LibraryBook?.Book?.AudibleProductId == libraryBook.Book.AudibleProductId) is ProcessBook entry
&& entry.Status is ProcessBookStatus.Completed
&& Queue.RemoveCompleted(entry);
public void AddDownloadPdf(DataLayer.LibraryBook libraryBook)
=> AddDownloadPdf(new List<DataLayer.LibraryBook>() { libraryBook });