From 21548af62fd5a21adffe99be0e955882b291dd7c Mon Sep 17 00:00:00 2001 From: xqzr <34030394+xqzr@users.noreply.github.com> Date: Wed, 23 Jul 2025 20:04:59 +0800 Subject: [PATCH] re Update xray.go --- infra/conf/xray.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/infra/conf/xray.go b/infra/conf/xray.go index 26f25cd0..f1d9fb08 100644 --- a/infra/conf/xray.go +++ b/infra/conf/xray.go @@ -522,9 +522,11 @@ func (c *Config) Build() (*core.Config, error) { config.App = append(config.App, serial.ToTypedMessage(statsConf)) } - var logConfMsg *serial.TypedMessage = serial.ToTypedMessage(DefaultLogConfig()) + var logConfMsg *serial.TypedMessage if c.LogConfig != nil { logConfMsg = serial.ToTypedMessage(c.LogConfig.Build()) + } else { + logConfMsg = serial.ToTypedMessage(DefaultLogConfig()) } // let logger module be the first App to start, // so that other modules could print log during initiating