Refactored Cache Cleanup code.

This commit is contained in:
Joseph Milazzo 2021-02-02 09:38:10 -06:00
parent 53e85317f9
commit 0f82b45b9d
7 changed files with 44 additions and 31 deletions

View file

@ -21,8 +21,8 @@ namespace API.Interfaces
/// <summary>
/// Clears cache directory of all volumes. This can be invoked from deleting a library or a series.
/// </summary>
/// <param name="volumeIds">Volumes that belong to that library. Assume the library might have been deleted before this invocation.</param>
void CleanupVolumes(int[] volumeIds);
/// <param name="chapterIds">Volumes that belong to that library. Assume the library might have been deleted before this invocation.</param>
void CleanupChapters(int[] chapterIds);
/// <summary>

View file

@ -26,5 +26,6 @@ namespace API.Interfaces
Task<Series> GetSeriesByIdAsync(int seriesId);
//Task<MangaFileDto> GetVolumeMangaFileDtos(int volumeId);
Task<int[]> GetChapterIdsForSeriesAsync(int[] seriesIds);
}
}

View file

@ -3,7 +3,7 @@
public interface ITaskScheduler
{
void ScanLibrary(int libraryId, bool forceUpdate = false);
void CleanupVolumes(int[] volumeIds);
void CleanupChapters(int[] chapterIds);
void ScanSeries(int libraryId, int seriesId);
}
}