Skip to content

Commit

Permalink
Fixed wrong return usage and added @throws docblock
Browse files Browse the repository at this point in the history
  • Loading branch information
iwalz committed Dec 24, 2012
1 parent 1675abc commit b1be18f
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions library/Zend/Http/Client/Adapter/Proxy.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,12 +85,13 @@ public function setOptions($options = array())
* @param string $host
* @param int $port
* @param boolean $secure
* @throws AdapterException\RuntimeException
*/
public function connect($host, $port = 80, $secure = false)
{
// If no proxy is set, fall back to Socket adapter
if (! $this->config['proxy_host']) {
return parent::connect($host, $port, $secure);
parent::connect($host, $port, $secure);
}

/* Url might require stream context even if proxy connection doesn't */
Expand All @@ -99,7 +100,7 @@ public function connect($host, $port = 80, $secure = false)
}

// Connect (a non-secure connection) to the proxy server
return parent::connect(
parent::connect(
$this->config['proxy_host'],
$this->config['proxy_port'],
false
Expand Down

0 comments on commit b1be18f

Please sign in to comment.