fix: Predis ping() returns Status object, cast to string before compare

This commit is contained in:
Lizandro Guarnizo
2026-03-11 21:41:58 -05:00
parent 7cca8342b5
commit 7586954e53
+1 -1
View File
@@ -52,7 +52,7 @@ try {
$ping = $redis->ping();
$health['checks']['redis'] = [
'status' => ($ping === 'PONG' || $ping === true) ? 'ok' : 'error',
'status' => ((string)$ping === 'PONG' || $ping === true) ? 'ok' : 'error',
'host' => getenv('REDIS_HOST') ?: 'redis'
];
} catch (Exception $e) {