@@ -97,7 +97,8 @@ public function resolve($name = null)
9797
9898 if (isset ($ this ->config [$ name ])) {
9999 return $ this ->connector ()->connect (
100- $ this ->parseConnectionConfigWithUrl ($ this ->config [$ name ]), $ options
100+ $ this ->parseConnectionConfiguration ($ this ->config [$ name ]),
101+ $ options
101102 );
102103 }
103104
@@ -117,7 +118,7 @@ public function resolve($name = null)
117118 protected function resolveCluster ($ name )
118119 {
119120 return $ this ->connector ()->connectToCluster (
120- $ this ->parseConnectionConfigWithUrl ($ this ->config ['clusters ' ][$ name ]),
121+ $ this ->parseConnectionConfiguration ($ this ->config ['clusters ' ][$ name ]),
121122 $ this ->config ['clusters ' ]['options ' ] ?? [],
122123 $ this ->config ['options ' ] ?? []
123124 );
@@ -157,16 +158,16 @@ protected function connector()
157158 }
158159
159160 /**
160- * Parse the redis configuration, hydrating options using a redis configuration URL if possible .
161+ * Parse the Redis connection configuration.
161162 *
162- * @param array $config
163+ * @param mixed $config
163164 * @return array
164165 */
165- protected function parseConnectionConfigWithUrl ($ config )
166+ protected function parseConnectionConfiguration ($ config )
166167 {
167- $ parsedConfig = (new ConfigurationUrlParser )->parseConfiguration ($ config );
168+ $ parsed = (new ConfigurationUrlParser )->parseConfiguration ($ config );
168169
169- return array_filter ($ parsedConfig , function ($ key ) {
170+ return array_filter ($ parsed , function ($ key ) {
170171 return ! in_array ($ key , ['driver ' , 'username ' ]);
171172 }, ARRAY_FILTER_USE_KEY );
172173 }
0 commit comments