Allow PubSub / MultiExec with Replication

This commit is contained in:
Josias Montag
2022-05-27 11:14:06 +02:00
committed by Till Krüss
parent 15244c9642
commit e5221fa13b
5 changed files with 12 additions and 12 deletions
+3 -3
View File
@@ -12,7 +12,7 @@
namespace Predis\Monitor;
use Predis\ClientInterface;
use Predis\Connection\AggregateConnectionInterface;
use Predis\Connection\Cluster\ClusterInterface;
use Predis\NotSupportedException;
/**
@@ -56,9 +56,9 @@ class Consumer implements \Iterator
*/
private function assertClient(ClientInterface $client)
{
if ($client->getConnection() instanceof AggregateConnectionInterface) {
if ($client->getConnection() instanceof ClusterInterface) {
throw new NotSupportedException(
'Cannot initialize a monitor consumer over aggregate connections.'
'Cannot initialize a monitor consumer over cluster connections.'
);
}