From f6d069ee587485aa87e3fa0fbad4053254e1a85e Mon Sep 17 00:00:00 2001
From: Alejandro Varela <epma01@gmail.com>
Date: Wed, 1 May 2019 22:12:27 +0200
Subject: [PATCH] Fix Redis with unix socket

Signed-off-by: Alejandro Varela <epma01@gmail.com>
---
 lib/private/RedisFactory.php | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/lib/private/RedisFactory.php b/lib/private/RedisFactory.php
index 754437c06c7..22d02e07c29 100644
--- a/lib/private/RedisFactory.php
+++ b/lib/private/RedisFactory.php
@@ -72,8 +72,10 @@ class RedisFactory {
 			}
 			if (isset($config['port'])) {
 				$port = $config['port'];
-			} else {
+			} else if ($host[0] !== '/') {
 				$port = 6379;
+			} else {
+				$port = null;
 			}
 			if (isset($config['timeout'])) {
 				$timeout = $config['timeout'];
-- 
GitLab