From 6928c084775ef582ac545259aa8ffc66c7736beb Mon Sep 17 00:00:00 2001 From: "guozhi.li" Date: Thu, 13 Oct 2022 10:19:50 +0800 Subject: [PATCH] support custom cmd. value is empty --- service/redis/client.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/service/redis/client.go b/service/redis/client.go index e3d070b2f..63d722a17 100644 --- a/service/redis/client.go +++ b/service/redis/client.go @@ -306,7 +306,8 @@ func (c *client) SetCustomRedisConfig(ip string, port string, configs []string, return err } // If the configuration is an empty line , it will result in an incorrect configSet, which will not run properly down the line. - if strings.TrimSpace(param) == "" || strings.TrimSpace(value) == "" { + // `config set save ""` should support + if strings.TrimSpace(param) == "" { continue } if err := c.applyRedisConfig(param, value, rClient); err != nil {