Skip to content

Commit 7b7a88f

Browse files
committed
PR feedback
1 parent 27b8cd8 commit 7b7a88f

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

internal/collector/nginxplusreceiver/factory.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ import (
1919
"github.com/nginx/agent/v3/internal/collector/nginxplusreceiver/internal/metadata"
2020
)
2121

22+
// nolint: ireturn
2223
const defaultTimeout = 10 * time.Second
2324

2425
// nolint: ireturn

internal/watcher/instance/nginx_process_parser.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -150,10 +150,8 @@ func (npp *NginxProcessParser) getInfo(ctx context.Context, proc *nginxprocess.P
150150
nginxInfo.ExePath = exePath
151151
nginxInfo.ProcessID = proc.PID
152152

153-
if confPath != "" {
153+
if nginxInfo.ConfPath = getNginxConfPath(ctx, nginxInfo); confPath != "" {
154154
nginxInfo.ConfPath = confPath
155-
} else {
156-
nginxInfo.ConfPath = getNginxConfPath(ctx, nginxInfo)
157155
}
158156

159157
loadableModules := getLoadableModules(nginxInfo)

0 commit comments

Comments
 (0)