From a4867c406de21bb1bd165e90a694e66f1c7e1210 Mon Sep 17 00:00:00 2001 From: qinguoyi <1532979219@qq.com> Date: Mon, 12 Aug 2024 19:52:22 +0800 Subject: [PATCH] fix:get configcache return nil need exit (#2094) --- center/sso/init.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/center/sso/init.go b/center/sso/init.go index f23998749..2051d001c 100644 --- a/center/sso/init.go +++ b/center/sso/init.go @@ -1,6 +1,7 @@ package sso import ( + "fmt" "log" "time" @@ -145,7 +146,7 @@ func Init(center cconf.Center, ctx *ctx.Context, configCache *memsto.ConfigCache } } if configCache == nil { - logger.Error("configCache is nil, sso initialization failed") + log.Fatalln(fmt.Errorf("configCache is nil, sso initialization failed")) } ssoClient.configCache = configCache userVariableMap := configCache.Get()