Skip to content

Commit

Permalink
Update class-wp-redis-object-cache.php
Browse files Browse the repository at this point in the history
  • Loading branch information
LeoColomb committed Jan 24, 2019
1 parent c81da44 commit 4688c55
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/class-wp-redis-object-cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,10 @@ public function __construct($fail_gracefully = true)
$this->redis_client .= sprintf(' (v%s)', Predis\Client::VERSION);
}

// Throws exception if Redis is unavailable
$this->redis->ping();
if (! defined('WP_REDIS_CLUSTER')) {
// Throws exception if Redis is unavailable
$this->redis->ping();
}

$this->redis_connected = true;
} catch (Exception $exception) {
Expand Down

0 comments on commit 4688c55

Please sign in to comment.