/// <summary> /// Performs the Notification /// </summary> public void Notify(object data) { var brewSessionComment = data as BrewSessionComment; var brewSession = this.RecipeService.GetBrewSessionById(brewSessionComment.BrewSessionId); var commenterUsername = this.UserService.GetUserSummaryById(brewSessionComment.UserId).Username; // Get users to notify var usersToNotify = this.NotificationService.GetUsersForBrewSessionCommentNotification(brewSessionComment.BrewSessionId, brewSessionComment.UserId); // Notify the Lot usersToNotify.ForEach(x => { var emailMessage = new BrewSessionCommentEmailMessage(this.WebSettings, brewSession, commenterUsername, x, brewSessionComment, this.RecipeUrlBuilder); this.EmailSender.Send(emailMessage); }); }