private function resolveDriver($driver)
    {
        if ($this->isIterable($driver)) {
            foreach ($driver as $drv) {
                try {
                    return $this->resolveOneDriver($drv);
                } catch (InvalidArgumentException $e) {
                    continue;
                }
            }

            throw new InvalidArgumentException(
                'Drivers cannot be resolved'
            );
        }

        return $this->resolveOneDriver($driver);
    }