Skip to content

Commit

Permalink
Don't check file system when host has protocol/scheme.
Browse files Browse the repository at this point in the history
  • Loading branch information
EarthlingDavey authored Sep 20, 2024
1 parent 95c727c commit fe5f0db
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion object-cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -1268,7 +1268,7 @@ public function build_client_parameters( $redis_server ) {
}
}

if ( file_exists( $redis_server['host'] ) && 'socket' === filetype( $redis_server['host'] ) ) { // unix socket connection.
if ( ! str_contains( $redis_server['host'], '://' ) && file_exists( $redis_server['host'] ) && 'socket' === filetype( $redis_server['host'] ) ) { // unix socket connection.
// port must be null or socket won't connect.
unset( $redis_server['port'] );
$port = null;
Expand Down

0 comments on commit fe5f0db

Please sign in to comment.