We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents edcca56 + 1e39856 commit 5cca2d1Copy full SHA for 5cca2d1
pkg/redis/PRedis.php
@@ -34,6 +34,10 @@ public function __construct(array $config)
34
'persisted' => false,
35
'database' => 0,
36
], $config);
37
+
38
+ // Predis client wants the key to be named "password"
39
+ $this->config['password'] = $this->config['pass'];
40
+ unset($this->config['pass']);
41
}
42
43
/**
@@ -91,9 +95,8 @@ public function connect(): void
91
95
92
96
$this->redis = new Client($this->config, ['exceptions' => true]);
93
97
94
- if ($this->config['pass']) {
- $this->redis->auth($this->config['pass']);
- }
98
+ // No need to pass "auth" here because Predis already handles
99
+ // this internally
100
101
$this->redis->connect();
102
0 commit comments