28 $this->data = array();
29 $types = Recipient\Type::getList();
30 foreach (
$data as $typeId => $count)
32 if (is_numeric($typeId))
34 $typeId = (int) $typeId;
36 $typeId = $typeId ?: Recipient\Type::EMAIL;
37 $typeId = is_numeric($typeId) ? $typeId : Recipient\Type::getId($typeId);
38 if ($typeId && !in_array($typeId, $types))
43 $this->data[$typeId] = (int) $count;