mirror of
https://github.com/Readarr/Readarr.git
synced 2026-04-21 22:04:31 -04:00
external notifications are now based on Events.
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
using System.Linq;
|
||||
using NzbDrone.Core.Datastore;
|
||||
|
||||
namespace NzbDrone.Core.ExternalNotification
|
||||
{
|
||||
public interface IExternalNotificationRepository : IBasicRepository<ExternalNotificationDefinition>
|
||||
{
|
||||
ExternalNotificationDefinition Get(string name);
|
||||
}
|
||||
|
||||
public class ExternalNotificationRepository : BasicRepository<ExternalNotificationDefinition>, IExternalNotificationRepository
|
||||
{
|
||||
public ExternalNotificationRepository(IObjectDatabase objectDatabase)
|
||||
: base(objectDatabase)
|
||||
{
|
||||
}
|
||||
|
||||
public ExternalNotificationDefinition Get(string name)
|
||||
{
|
||||
return Queryable.SingleOrDefault(c => c.Name.ToLower() == name.ToLower());
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user