Commit 298db7a0 authored by catch's avatar catch

Issue #1887046 by Sutharsan: Convert drupal_http_request() usage in install.core.inc to Guzzle.

parent 6d5c2113
......@@ -356,6 +356,17 @@ function install_begin_request(&$install_state) {
// Register a module handler for managing enabled modules.
$container
->register('module_handler', 'Drupal\Core\Extension\ModuleHandler');
// Register the Guzzle HTTP client for fetching translation files from a
// remote translation server such as localization.drupal.org.
$container->register('http_default_client', 'Guzzle\Http\Client')
->addArgument(NULL)
->addArgument(array(
'curl.CURLOPT_TIMEOUT' => 30.0,
'curl.CURLOPT_MAXREDIRS' => 3,
))
->addMethodCall('setUserAgent', array('Drupal (+http://drupal.org/)'));
drupal_container($container);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment