providers = $providers; } #[Override] public function isAllowedUri(string $uri): bool { return true; } #[Override] public function fetch(string $uri): array { $lastException = null; $providers = array_filter($this->providers, static fn(RemoteProviderInterface $provider): bool => $provider->isAllowedUri($uri)); foreach ($providers as $provider) { try { return $provider->fetch($uri); } catch (ExceptionInterface $e) { $lastException = $e; } } throw new RuntimeException('Unable to fetch issuer metadata', 0, $lastException); } }