Skip to content

Commit

Permalink
[10.x] Support for phpredis 6.0.0 (#48364)
Browse files Browse the repository at this point in the history
* Support for phpredis 6.0.0, fix for OPT_SLAVE_FAILOVER

* PHPSTAN: Remove ignored error "Access to undefined constant"
  • Loading branch information
stemis authored Sep 11, 2023
1 parent 45423d1 commit 21968a1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion phpstan.src.neon.dist
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ parameters:
level: 0
ignoreErrors:
- "#\\(void\\) is used#"
- "#Access to undefined constant#"
- "#Access to an undefined property#"
- "#Call to an undefined method#"
- "#but return statement is missing.#"
Expand Down
2 changes: 1 addition & 1 deletion src/Illuminate/Redis/Connectors/PhpRedisConnector.php
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ protected function createRedisClusterInstance(array $servers, array $options)
}

if (! empty($options['failover'])) {
$client->setOption(Redis::OPT_SLAVE_FAILOVER, $options['failover']);
$client->setOption(RedisCluster::OPT_SLAVE_FAILOVER, $options['failover']);
}

if (! empty($options['name'])) {
Expand Down

0 comments on commit 21968a1

Please sign in to comment.