You are here

public function DrupalApplication::getHttpOptions in CMS Content Sync 8

Same name and namespace in other branches
  1. 2.1.x src/SyncCoreInterface/DrupalApplication.php \Drupal\cms_content_sync\SyncCoreInterface\DrupalApplication::getHttpOptions()
  2. 2.0.x src/SyncCoreInterface/DrupalApplication.php \Drupal\cms_content_sync\SyncCoreInterface\DrupalApplication::getHttpOptions()

File

src/SyncCoreInterface/DrupalApplication.php, line 174

Class

DrupalApplication
Class DrupalApplication.

Namespace

Drupal\cms_content_sync\SyncCoreInterface

Code

public function getHttpOptions() {
  $options = [];

  // Allow to set a custom timeout for Sync Core requests.
  global $config;
  $config_name = 'cms_content_sync.sync_core_request_timeout';
  if (!empty($config[$config_name]) && is_int($config[$config_name])) {
    $options['timeout'] = $config[$config_name];
  }
  return $options;
}