Upstream Changes to DownloadClients and Indexers

This commit is contained in:
Qstick
2017-10-26 23:21:06 -04:00
parent f6d1b77b45
commit 13bfb73ee9
80 changed files with 1521 additions and 654 deletions
@@ -1,26 +1,20 @@
using System.Linq;
using NzbDrone.Core.Datastore;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.ThingiProvider;
using NzbDrone.Core.ThingiProvider.Status;
namespace NzbDrone.Core.Indexers
{
public interface IIndexerStatusRepository : IProviderRepository<IndexerStatus>
public interface IIndexerStatusRepository : IProviderStatusRepository<IndexerStatus>
{
IndexerStatus FindByIndexerId(int indexerId);
}
}
public class IndexerStatusRepository : ProviderStatusRepository<IndexerStatus>, IIndexerStatusRepository
public class IndexerStatusRepository : ProviderRepository<IndexerStatus>, IIndexerStatusRepository
{
public IndexerStatusRepository(IMainDatabase database, IEventAggregator eventAggregator)
: base(database, eventAggregator)
{
}
public IndexerStatus FindByIndexerId(int indexerId)
{
return Query.Where(c => c.ProviderId == indexerId).SingleOrDefault();
}
}
}