public function OptOutInterface::getOptOutAccounts in Mass Contact 8
Finds a list of users that have opted out of emails.
Parameters
\Drupal\mass_contact\Entity\MassContactCategoryInterface[] $categories: An array of categories.
Return value
int[] An array of account IDs that have opted out. This includes global opt-out as well. If opt-outs are disabled, this method always returns an empty array.
1 method overrides OptOutInterface::getOptOutAccounts()
- OptOut::getOptOutAccounts in src/
OptOut.php - Finds a list of users that have opted out of emails.
File
- src/
OptOutInterface.php, line 21
Class
- OptOutInterface
- A service for managing user opt-outs of mass contact emails.
Namespace
Drupal\mass_ContactCode
public function getOptOutAccounts(array $categories = []);