Skip to content

Commit

Permalink
Fixed the issue with notifications not sending
Browse files Browse the repository at this point in the history
  • Loading branch information
tidusjar committed Sep 23, 2018
1 parent 5596308 commit 87cc5d4
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions src/Ombi.Notifications/NotificationMessageCurlys.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ public class NotificationMessageCurlys
public void Setup(NotificationOptions opts, FullBaseRequest req, CustomizationSettings s, UserNotificationPreferences pref)
{
LoadIssues(opts);
UserPreference = pref.Enabled ? pref.Value : string.Empty;
if (pref != null)
{
UserPreference = pref.Enabled ? pref.Value : string.Empty;
}

string title;
if (req == null)
{
Expand Down Expand Up @@ -62,7 +66,10 @@ public void Setup(NotificationOptions opts, FullBaseRequest req, CustomizationSe
public void Setup(NotificationOptions opts, AlbumRequest req, CustomizationSettings s, UserNotificationPreferences pref)
{
LoadIssues(opts);
UserPreference = pref.Enabled ? pref.Value : string.Empty;
if (pref != null)
{
UserPreference = pref.Enabled ? pref.Value : string.Empty;
}
string title;
if (req == null)
{
Expand Down Expand Up @@ -106,7 +113,10 @@ public void SetupNewsletter(CustomizationSettings s, OmbiUser username)
public void Setup(NotificationOptions opts, ChildRequests req, CustomizationSettings s, UserNotificationPreferences pref)
{
LoadIssues(opts);
UserPreference = pref.Enabled ? pref.Value : string.Empty;
if (pref != null)
{
UserPreference = pref.Enabled ? pref.Value : string.Empty;
}
string title;
if (req == null)
{
Expand Down

0 comments on commit 87cc5d4

Please sign in to comment.