Remove unused function
authorEileen McNaughton <emcnaughton@wikimedia.org>
Sat, 4 Sep 2021 22:14:24 +0000 (10:14 +1200)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Sat, 4 Sep 2021 22:14:24 +0000 (10:14 +1200)
CRM/Mailing/BAO/Mailing.php

index 2e53e4a388f2fc7b9445eed7694f4c53ab51cb95..155e65e79132eac1ff4f9bece9785920bd841d37 100644 (file)
@@ -449,39 +449,6 @@ class CRM_Mailing_BAO_Mailing extends CRM_Mailing_DAO_Mailing {
     return [$location_filter, $orderBy];
   }
 
-  /**
-   * @param string $type
-   *
-   * @return array
-   */
-  private function _getMailingGroupIds($type = 'Include') {
-    $mailingGroup = new CRM_Mailing_DAO_MailingGroup();
-    $group = CRM_Contact_DAO_Group::getTableName();
-    if (!isset($this->id)) {
-      // we're just testing tokens, so return any group
-      $query = "SELECT   id AS entity_id
-                      FROM     $group
-                      ORDER BY id
-                      LIMIT 1";
-    }
-    else {
-      $mg = CRM_Mailing_DAO_MailingGroup::getTableName();
-      $query = "SELECT entity_id
-                      FROM   $mg
-                      WHERE  mailing_id = {$this->id}
-                      AND    group_type = '$type'
-                      AND    entity_table = '$group'";
-    }
-    $mailingGroup->query($query);
-
-    $groupIds = [];
-    while ($mailingGroup->fetch()) {
-      $groupIds[] = $mailingGroup->entity_id;
-    }
-
-    return $groupIds;
-  }
-
   /**
    * Returns the regex patterns that are used for preparing the text and html templates.
    *