浏览代码

Fix bug trying to switch to an unknown connection.

Daniele Alessandri 9 年之前
父节点
当前提交
18e846c2ad
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/Connection/Aggregate/SentinelReplication.php

+ 1 - 1
src/Connection/Aggregate/SentinelReplication.php

@@ -570,7 +570,7 @@ class SentinelReplication implements ReplicationInterface
             $connection = $this->getConnectionById($connection);
         }
 
-        if ($connection === $this->current) {
+        if ($connection && $connection === $this->current) {
             return;
         }