public function exportOrders(OrderVisitor $orderVisitor, ProgressBar $bar): bool
    {
        $logger = $this->getLogger();

        $bar->start($count = count($orderVisitor));

        $logger->debug('Started the order export.', ['count' => $count]);

        foreach ($orderVisitor() as $num => $order) {
            set_time_limit(0);

            $this->exportOrder($order, $num);

            $bar->advance();
        }

        $logger->debug('Finished the order export.', ['count' => $count]);

        $bar->finish();

        return true;
    }