mirror of
https://github.com/Readarr/Readarr
synced 2026-04-11 15:33:23 +02:00
26 lines
804 B
C#
26 lines
804 B
C#
using NzbDrone.Core.Notifications;
|
|
using Readarr.Http;
|
|
|
|
namespace Readarr.Api.V1.Notifications
|
|
{
|
|
[V1ApiController]
|
|
public class NotificationController : ProviderControllerBase<NotificationResource, INotification, NotificationDefinition>
|
|
{
|
|
public static readonly NotificationResourceMapper ResourceMapper = new NotificationResourceMapper();
|
|
|
|
public NotificationController(NotificationFactory notificationFactory)
|
|
: base(notificationFactory, "notification", ResourceMapper)
|
|
{
|
|
}
|
|
|
|
protected override void Validate(NotificationDefinition definition, bool includeWarnings)
|
|
{
|
|
if (!definition.Enable)
|
|
{
|
|
return;
|
|
}
|
|
|
|
base.Validate(definition, includeWarnings);
|
|
}
|
|
}
|
|
}
|