Skip to content

Commit

Permalink
Added tests for 2.0.8
Browse files Browse the repository at this point in the history
  • Loading branch information
gigablah committed Aug 22, 2013
1 parent e0d022c commit ebabffc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Sphinx/SphinxClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ public function isConnectError()
* @param integer $port
*
* @return SphinxClient
* @throws \InvalidArgumentException When host name is not a valid string or invalid port number
* @throws \InvalidArgumentException When host name or port number is invalid
*/
public function setServer($host, $port = 0)
{
Expand All @@ -282,7 +282,7 @@ public function setServer($host, $port = 0)
throw new \InvalidArgumentException('Port number must be an integer between 0 and 65536.');
}

$this->port = ( $port==0 ) ? 9312 : $port;
$this->port = $port ?: 9312;

$this->path = '';

Expand Down

0 comments on commit ebabffc

Please sign in to comment.