protected function getDataListObjects(FormConfigInterface $config, array $objects)
    {
        $limit = $this->getLimit($config instanceof FormConfigListInterface ? $config->getLimit() : null);
        $dataList = $this->getDataList($config);

        if (null !== $limit && \count($dataList) > $limit) {
            $msg = $this->translator->trans('form_handler.size_exceeds', [
                '{{ limit }}' => $limit,
            ], 'FxpResource');

            throw new InvalidResourceException(sprintf($msg, $limit));
        }

        if (0 === \count($objects) && $config instanceof FormConfigListInterface) {
            $objects = $config->convertObjects($dataList);
        }

        $dataList = array_values($dataList);
        $objects = array_values($objects);

        return [$dataList, $objects];
    }