Remove inline if clauses

This commit is contained in:
jrenslin committed 2021-02-06 20:08:37 +01:00
1 parent 217e1fc86b
commit 8aa9d94acf
4 files changed
+69 -23

No files matched your search

+3 -1
View File
@@ -48,7 +48,9 @@ public static function shutdown_cache_through_redis(string $redisKey, int $expir
*/
public static function serve_page_through_redis_cache(string $redisKey, int $expiry = 3600):string {
if (PHP_SAPI === 'cli') return '';
if (PHP_SAPI === 'cli') {
return '';
}
$redis = new Redis();
$redis->connect(self::$redis_host, self::$redis_port, 1, null, 0, 0, ['auth' => [MD_CONF::$redis_pw]]);