Fix and reword some exception messages.

This commit is contained in:
Daniele Alessandri
2013-12-16 13:17:45 +01:00
parent 43f278fb71
commit 0f34f41ccf
70 changed files with 172 additions and 180 deletions
@@ -59,7 +59,7 @@ class ComposableStreamConnection extends StreamConnection implements ComposableC
public function readBuffer($length)
{
if ($length <= 0) {
throw new \InvalidArgumentException('Length parameter must be greater than 0');
throw new \InvalidArgumentException('Length parameter must be greater than 0.');
}
$value = '';
@@ -69,7 +69,7 @@ class ComposableStreamConnection extends StreamConnection implements ComposableC
$chunk = fread($socket, $length);
if ($chunk === false || $chunk === '') {
$this->onConnectionError('Error while reading bytes from the server');
$this->onConnectionError('Error while reading bytes from the server.');
}
$value .= $chunk;
@@ -90,7 +90,7 @@ class ComposableStreamConnection extends StreamConnection implements ComposableC
$chunk = fgets($socket);
if ($chunk === false || $chunk === '') {
$this->onConnectionError('Error while reading line from the server');
$this->onConnectionError('Error while reading line from the server.');
}
$value .= $chunk;