Skip to content
This repository was archived by the owner on Feb 5, 2024. It is now read-only.

Fixed error message if client type is not available. #7

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/Doctrine/CouchDB/CouchDBClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ static public function create(array $options)
$options = array_merge($defaults, $options);

if (!isset(self::$clients[$options['type']])) {
throw new \InvalidArgumentException(sprintf('There is no client implementation registered for %s, valid options are %s',
$options['type'], array_keys(self::$clients)
throw new \InvalidArgumentException(sprintf('There is no client implementation registered for %s, valid options are [%s]',
$options['type'], implode('|', array_keys(self::$clients))
));
}
$connectionClass = self::$clients[$options['type']];
Expand Down
1 change: 1 addition & 0 deletions lib/Doctrine/CouchDB/HTTP/StreamClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ public function request( $method, $path, $data = null, $raw = false )
$body = '';
while ( !feof( $httpFilePointer ) ) {
$body .= fgets( $httpFilePointer );
echo fgets( $httpFilePointer )."\n";
}

$metaData = stream_get_meta_data( $httpFilePointer );
Expand Down