event based cleanup when a series is deleted.

This commit is contained in:
Keivan Beigi 2013-03-05 11:49:34 -08:00
commit 4877ce405e
11 changed files with 61 additions and 87 deletions

View file

@ -14,6 +14,7 @@ namespace NzbDrone.Core.Datastore
void Delete(int id);
IList<TModel> InsertMany(IList<TModel> model);
IList<TModel> UpdateMany(IList<TModel> model);
void DeleteMany(IList<TModel> model);
void Purge();
bool HasItems();
}
@ -64,6 +65,11 @@ namespace NzbDrone.Core.Datastore
return ObjectDatabase.UpdateMany(model);
}
public void DeleteMany(IList<TModel> model)
{
ObjectDatabase.DeleteMany(model);
}
public TModel Upsert(TModel model)
{
if (model.Id == 0)