private static function validateReportPeriod($period)
{
$availablePeriods = array('day', 'week', 'month', 'never');
if (!in_array($period, $availablePeriods)) {
throw new Exception('Period schedule must be one of the following: ' . implode(', ', $availablePeriods));
}
}