private async Task SendUnnotifiedStoriesToUserAsync(User user, IEnumerable <Story> currentStories) { var userNotifications = await _userStoryNotificationStorage .GetUserNotificationsAsync(user.Id); var unnotifiedStories = currentStories .Where(s => s.Points > user.StoriesMinPointsToNotify) .Where(s => !userNotifications.Any(un => un.StoryId == s.Id)); foreach (var story in unnotifiedStories) { try { var message = $"{story.Id}\n{story.Title}\n{story.Url}"; await _userMessageSender.SendAsync(user, message); await _userStoryNotificationStorage .SaveUserNotificationAsync(user.Id, story.Id); } catch (Exception) { } } }