Promote multibulk response iterators as Predis response objects.

Multibulk response iterators will not be passed anymore to the response
parser method of the command that generated the response. Pipeline and
transaction abstractions still consume interators returned as response
items.
This commit is contained in:
Daniele Alessandri
2012-08-21 16:21:07 +02:00
parent 8d7f5099c4
commit 9df9dbdedc
11 changed files with 79 additions and 43 deletions
-6
View File
@@ -11,8 +11,6 @@
namespace Predis\Command;
use Predis\Iterator\MultiBulkResponseTuple;
/**
* @link http://redis.io/commands/zrange
* @author Daniele Alessandri <suppakilla@gmail.com>
@@ -90,10 +88,6 @@ class ZSetRange extends PrefixableCommand
public function parseResponse($data)
{
if ($this->withScores()) {
if ($data instanceof \Iterator) {
return new MultiBulkResponseTuple($data);
}
$result = array();
for ($i = 0; $i < count($data); $i++) {