Commit e4b6d3c4 authored by Thomas Hamel's avatar Thomas Hamel
Browse files

WIP

parent c429ea22
Loading
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -7,7 +7,7 @@ use Assert\AssertionFailedException;
use Doctrine\DBAL\Connection as DbConnection;
use Generator;
use Psr\Container\ContainerInterface;
use UnicaenDbImport\Domain\SelectGeneratorInterface;
use UnicaenDbImport\Domain\SelectProviderInterface;
use UnicaenDbImport\Connection\ApiConnection;
use UnicaenDbImport\Domain\Destination;
use UnicaenDbImport\Domain\Import;
@@ -355,10 +355,10 @@ class ConfigFactory
        if ($select && is_string($select) && $this->container->has($select)) {
            $serviceName = $select;
            $service = $this->container->get($serviceName);
            if (!$service instanceof SelectGeneratorInterface) {
            if (!$service instanceof SelectProviderInterface) {
                throw ConfigException::invalidValueForKey(
                    $key,
                    "Service implémentant " . SelectGeneratorInterface::class
                    "Service implémentant " . SelectProviderInterface::class
                );
            }
            $sourceConfig[$key] = $service->getSelects();
+1 −1
Original line number Diff line number Diff line
@@ -2,7 +2,7 @@

namespace UnicaenDbImport\Domain;

interface SelectGeneratorInterface
interface SelectProviderInterface
{
    public function getSelects(): iterable;
}
 No newline at end of file