mirror of
https://github.com/Sonarr/Sonarr.git
synced 2026-04-23 22:25:56 -04:00
Translate Notifications settings
This commit is contained in:
@@ -2,6 +2,7 @@ using System.Collections.Generic;
|
||||
using FluentValidation.Results;
|
||||
using NzbDrone.Common.Extensions;
|
||||
using NzbDrone.Core.Configuration;
|
||||
using NzbDrone.Core.Localization;
|
||||
using NzbDrone.Core.MediaFiles;
|
||||
using NzbDrone.Core.Tv;
|
||||
using NzbDrone.Core.Validation;
|
||||
@@ -12,8 +13,8 @@ namespace NzbDrone.Core.Notifications.Webhook
|
||||
{
|
||||
private readonly IWebhookProxy _proxy;
|
||||
|
||||
public Webhook(IWebhookProxy proxy, IConfigFileProvider configFileProvider, IConfigService configService)
|
||||
: base(configFileProvider, configService)
|
||||
public Webhook(IWebhookProxy proxy, IConfigFileProvider configFileProvider, IConfigService configService, ILocalizationService localizationService)
|
||||
: base(configFileProvider, configService, localizationService)
|
||||
{
|
||||
_proxy = proxy;
|
||||
}
|
||||
@@ -89,7 +90,7 @@ namespace NzbDrone.Core.Notifications.Webhook
|
||||
}
|
||||
catch (WebhookException ex)
|
||||
{
|
||||
return new NzbDroneValidationFailure("Url", ex.Message);
|
||||
return new NzbDroneValidationFailure("Url", _localizationService.GetLocalizedString("NotificationsValidationUnableToSendTestMessage", new Dictionary<string, object> { { "exceptionMessage", ex.Message } }));
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user