private static function flattenDaysIntervals(array $days): array
    {
        \ksort($days);

        $flattenDays = [];
        foreach ($days as $dayOfWeek => $intervals) {
            $flattenDays[] = DayBuilder::fromArray($dayOfWeek, $intervals);
        }

        return $flattenDays;
    }