mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-16 02:02:55 -07:00
Resolved #75
This commit is contained in:
parent
0585ff73ec
commit
f64ccd7327
2 changed files with 24 additions and 3 deletions
|
@ -77,7 +77,15 @@ namespace PlexRequests.Services.Notification
|
|||
|
||||
private bool ValidateConfiguration()
|
||||
{
|
||||
return !Settings.Enabled && !string.IsNullOrEmpty(Settings.AccessToken);
|
||||
if (!Settings.Enabled)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (string.IsNullOrEmpty(Settings.AccessToken))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
private PushbulletNotificationSettings GetSettings()
|
||||
|
@ -106,8 +114,8 @@ namespace PlexRequests.Services.Notification
|
|||
|
||||
private bool PushIssue(NotificationModel model)
|
||||
{
|
||||
var message = $"A new issue: {model.Title} has been reported by user: {model.User} for the title: {model.Body}";
|
||||
var pushTitle = $"Plex Requests: A new issue has been reported for {model.Body}";
|
||||
var message = $"A new issue: {model.Body} has been reported by user: {model.User} for the title: {model.Title}";
|
||||
var pushTitle = $"Plex Requests: A new issue has been reported for {model.Title}";
|
||||
try
|
||||
{
|
||||
var result = PushbulletApi.Push(Settings.AccessToken, pushTitle, message, Settings.DeviceIdentifier);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue