diff --git a/core/modules/update/src/UpdateFetcher.php b/core/modules/update/src/UpdateFetcher.php index d6101b7392..8a322ac52a 100644 --- a/core/modules/update/src/UpdateFetcher.php +++ b/core/modules/update/src/UpdateFetcher.php @@ -70,7 +70,7 @@ public function __construct(ConfigFactoryInterface $config_factory, ClientInterf */ public function fetchProjectData(array $project, $site_key = '') { $url = $this->buildFetchUrl($project, $site_key); - return $this->doRequestWithHTTPFallback($url, ['headers' => ['Accept' => 'text/xml']], $this->withHttpFallback); + return $this->doRequest($url, ['headers' => ['Accept' => 'text/xml']], $this->withHttpFallback); } /** @@ -88,7 +88,7 @@ public function fetchProjectData(array $project, $site_key = '') { * * @return string */ - protected function doRequestWithHTTPFallback($url, array $options, $with_http_fallback) { + protected function doRequest($url, array $options, $with_http_fallback) { $data = ''; try { $data = (string) $this->httpClient @@ -100,7 +100,7 @@ protected function doRequestWithHTTPFallback($url, array $options, $with_http_fa if ($with_http_fallback && strpos($exception->getMessage(), 'SSL certificate problem: Invalid') !== FALSE) { $url = str_replace('https://', 'http://', $url); - return $this->doRequestWithHTTPFallback($url, $options, FALSE); + return $this->doRequest($url, $options, FALSE); } } return $data;