|
|
|
@ -128,6 +128,10 @@ namespace NzbDrone.Core.Providers
|
|
|
|
|
//Delete Files, Episdes, Seasons then the Series
|
|
|
|
|
//Can't use providers because episode provider needs series provider - Cyclic Dependency Injection, this will work
|
|
|
|
|
|
|
|
|
|
Logger.Debug("Deleting History Items from DB for Series: {0}", series.SeriesId);
|
|
|
|
|
var episodes = series.Episodes.Select(e => e.EpisodeId).ToList();
|
|
|
|
|
episodes.ForEach(e => _repository.DeleteMany<History>(h => h.EpisodeId == e));
|
|
|
|
|
|
|
|
|
|
Logger.Debug("Deleting EpisodeFiles from DB for Series: {0}", series.SeriesId);
|
|
|
|
|
_repository.DeleteMany(series.EpisodeFiles);
|
|
|
|
|
|
|
|
|
|