diff options
author | Michael Stilkerich <ms@mike2k.de> | 2022-11-11 15:21:57 +0300 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2022-11-11 15:22:59 +0300 |
commit | 473eec4a8a271c44380fcea67289cc49e8137d16 (patch) | |
tree | 93223975c964fcdaf67ebb7284f50802f53229be | |
parent | 1c7b4baa853db04e76cbb8cc226ea9427a1285a9 (diff) |
Pass port 0 as integer to Redis::connect() with unix socket (#8749)
The second parameter to Redis::connect() is an int parameter. Passing
null for it will trigger a PHP deprecation notice with PHP 8.1.
The Redis::connect() documentation shows that a 0 is used for the port
parameter in the examples with unix sockets where parameters beyond the
second parameter are set.
-rw-r--r-- | program/lib/Roundcube/cache/redis.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/program/lib/Roundcube/cache/redis.php b/program/lib/Roundcube/cache/redis.php index b1ba5364f..849d06175 100644 --- a/program/lib/Roundcube/cache/redis.php +++ b/program/lib/Roundcube/cache/redis.php @@ -110,7 +110,7 @@ class rcube_cache_redis extends rcube_cache if (substr($redis_host, 0, 7) === 'unix://') { $host = substr($port, 2); - $port = null; + $port = 0; } else { // set default values if not set |