Answers.Body: <p>It seems that the bugfix which fixed this for smart groups also did it for the groups. Our last mailing sending after upgrading to CiviCRM 5.30.1 resolved this issue. No mails have been sent to contacts in trash.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-01T09:36:49.947Z
Answers.LastActivityDate: 2020-11-01T09:36:49.947Z
Answers.UserDisplayName: Tobias Krause
Body: <p>We discovered a bug on this weekend with our last newsletter. We use CiviMail to send our newsletter to all contacts within our &quot;Newsletter&quot; group. As usual we collected the group as the recipients in the mailing form. After the update to CiviCRM 5.29.1 we made last week we realized that the newsletter was sent to group members which are delete already.</p>
  <p>I checked if these contacts were included to the newsletter recipients before but I did not find deleted contacts in the list of recipients for newsletters sent before this update.</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-10-12T20:53:04.573Z
Comments.Text: I've created https://lab.civicrm.org/dev/core/-/issues/2119 to track this
Comments.UserDisplayName: eileen
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-10-12T22:27:37.740Z
Comments.Text: Hi Tobias - can you confirm a couple of things to help us replicate this issue. Is your "Newsletter" group a smart group?  Do you have the FlexMailer extension installed. The "Deleted" contacts you reference are they in trash? or permanently deleted?
Comments.UserDisplayName: Luke Stewart
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-10-13T06:11:24.277Z
Comments.Text: The newsletter group is not a smart group, no. We do not use the Flexmailer extension and yes, the deleted contacts are in trash, they are not permanently deleted.
Comments.UserDisplayName: Tobias Krause
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2020-10-13T16:16:10.260Z
Comments.Text: This bug is also in 5.30 - just tested it with a smart group. A contact in the trash was emailed.
Comments.UserDisplayName: Andy Clark
Tags: <civimail><contacts><groups><deleted><civigroup>
Title: Mailing to contacts in a group - deleted contacts were included to the list of recipients
ThreadText: # Mailing to contacts in a group - deleted contacts were included to the list of recipients
  
  (Asked by: username_0 on 2020-10-12)
  
  We discovered a bug on this weekend with our last newsletter. We use CiviMail to send our newsletter to all contacts within our "Newsletter" group. As usual we collected the group as the recipients in the mailing form. After the update to CiviCRM 5.29.1 we made last week we realized that the newsletter was sent to group members which are delete already.
  
  I checked if these contacts were included to the newsletter recipients before but I did not find deleted contacts in the list of recipients for newsletters sent before this update.
  
  **Tags:** civimail, contacts, groups, deleted, civigroup
  
  > **Comments:**
  > **username_1**: I've created https://lab.civicrm.org/dev/core/-/issues/2119 to track this  
  > **username_2**: Hi Tobias - can you confirm a couple of things to help us replicate this issue. Is your "Newsletter" group a smart group?  Do you have the FlexMailer extension installed. The "Deleted" contacts you reference are they in trash? or permanently deleted?  
  > **username_0**: The newsletter group is not a smart group, no. We do not use the Flexmailer extension and yes, the deleted contacts are in trash, they are not permanently deleted.  
  > **username_3**: This bug is also in 5.30 - just tested it with a smart group. A contact in the trash was emailed.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2020-11-01. Score: 2
  
  It seems that the bugfix which fixed this for smart groups also did it for the groups. Our last mailing sending after upgrading to CiviCRM 5.30.1 resolved this issue. No mails have been sent to contacts in trash.
  
  
  ---
  
  