/** * Get number of unique beacons given an event and a set of dates * * @param string $token Event * @param string $event Token * @param array $dates Dates * * @return integer Number of hits */ public function getBeaconsUnique($token, $event, array $dates) { $keys = []; foreach ($dates as $date) { $keys[] = $this->generateEntryKey($token, $event, $date) . '_unique'; } return (int) $this->redis->pfCount($keys); }