public function SendinblueApiV3::countUserlists in SendinBlue 8
Same name and namespace in other branches
- 8.2 src/Tools/Api/SendinblueApiV3.php \Drupal\sendinblue\Tools\Api\SendinblueApiV3::countUserlists()
Count all users of lists.
Parameters
array $listids: An array of lists.
Return value
int Number of users.
Overrides SendInBlueApiInterface::countUserlists
File
- src/
Tools/ Api/ SendinblueApiV3.php, line 366
Class
- SendinblueApiV3
- Sendinblue REST client.
Namespace
Drupal\sendinblue\Tools\ApiCode
public function countUserlists(array $listids = []) {
$total = 0;
foreach ($listids as $listid) {
$userList = $this->sibListsApi
->getContactsFromList($listid);
$total += $userList
->getCount();
}
return $total;
}