Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorotwell committed May 22, 2016
1 parent 590d4a4 commit 1576199
Showing 1 changed file with 13 additions and 15 deletions.
28 changes: 13 additions & 15 deletions src/Illuminate/Mail/TransportManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,19 @@ protected function createLogDriver()
return new LogTransport($this->app->make('Psr\Log\LoggerInterface'));
}

/**
* Get a fresh Guzzle HTTP client instance.
*
* @param array $config
* @return HttpClient
*/
protected function getHttpClient($config)
{
$guzzleConfig = Arr::get($config, 'guzzle', []);

return new HttpClient(Arr::add($guzzleConfig, 'connect_timeout', 60));
}

/**
* Get the default cache driver name.
*
Expand All @@ -164,19 +177,4 @@ public function setDefaultDriver($name)
{
$this->app['config']['mail.driver'] = $name;
}

/**
* get configured http client.
* @param $config
* @return HttpClient
*/
protected function getHttpClient($config)
{
$guzzleConfig = Arr::get($config, 'guzzle', []);

// add default config for timeout
$guzzleConfig = Arr::add($guzzleConfig, 'connect_timeout', 60);

return new HttpClient($guzzleConfig);
}
}

0 comments on commit 1576199

Please sign in to comment.