diff --git a/src/Ombi.Notifications/Agents/LegacyMobileNotification.cs b/src/Ombi.Notifications/Agents/LegacyMobileNotification.cs index 78fdc6304..5ac92d5bf 100644 --- a/src/Ombi.Notifications/Agents/LegacyMobileNotification.cs +++ b/src/Ombi.Notifications/Agents/LegacyMobileNotification.cs @@ -306,7 +306,7 @@ namespace Ombi.Notifications.Agents { if (await SubsribedUsers.AnyAsync()) { - foreach (var user in SubsribedUsers.Include(x => x.NotificationUserIds)) + foreach (var user in SubsribedUsers) { var notificationId = user.NotificationUserIds; if (notificationId.Any()) diff --git a/src/Ombi.Notifications/Agents/MobileNotification.cs b/src/Ombi.Notifications/Agents/MobileNotification.cs index 3ac2bd7fe..61526802c 100644 --- a/src/Ombi.Notifications/Agents/MobileNotification.cs +++ b/src/Ombi.Notifications/Agents/MobileNotification.cs @@ -336,7 +336,7 @@ namespace Ombi.Notifications.Agents { if (await SubsribedUsers.AnyAsync()) { - foreach (var user in SubsribedUsers.Include(x => x.NotificationUserIds)) + foreach (var user in SubsribedUsers) { var notificationId = user.NotificationUserIds; if (notificationId.Any()) diff --git a/src/Ombi.Notifications/BaseNotification.cs b/src/Ombi.Notifications/BaseNotification.cs index c9404eb2c..465ccd22c 100644 --- a/src/Ombi.Notifications/BaseNotification.cs +++ b/src/Ombi.Notifications/BaseNotification.cs @@ -191,7 +191,7 @@ namespace Ombi.Notifications protected IQueryable GetSubscriptions(int requestId, RequestType type) { - var subs = RequestSubscription.GetAll().Include(x => x.User).Where(x => x.RequestId == requestId && type == x.RequestType); + var subs = RequestSubscription.GetAll().Include(x => x.User).ThenInclude(x => x.NotificationUserIds).Where(x => x.RequestId == requestId && type == x.RequestType); return subs.Select(x => x.User); }