fix: proxy not set on subnet logger webhook sometimes (#17320)

This commit is contained in:
Shireesh Anjal 2023-05-31 20:39:09 +05:30 committed by GitHub
parent fb5ce3b87a
commit 817e85a3e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -546,7 +546,7 @@ func (a adminAPIHandlers) GetConfigHandler(w http.ResponseWriter, r *http.Reques
// setLoggerWebhookSubnetProxy - Sets the logger webhook's subnet proxy value to
// one being set for subnet proxy
func setLoggerWebhookSubnetProxy(subSys string, cfg config.Config) bool {
if subSys == config.SubnetSubSys {
if subSys == config.SubnetSubSys || subSys == config.LoggerWebhookSubSys {
subnetWebhookCfg := cfg[config.LoggerWebhookSubSys][subnet.LoggerWebhookName]
loggerWebhookSubnetProxy := subnetWebhookCfg.Get(logger.Proxy)
subnetProxy := cfg[config.SubnetSubSys][config.Default].Get(logger.Proxy)