MCPcopy Create free account
hub / github.com/prometheus/common / SetDirectory

Method SetDirectory

config/http_config.go:151–157  ·  view source on GitHub ↗

SetDirectory joins any relative file paths with dir.

(dir string)

Source from the content-addressed store, hash-verified

149
150// SetDirectory joins any relative file paths with dir.
151func (a *BasicAuth) SetDirectory(dir string) {
152 if a == nil {
153 return
154 }
155 a.PasswordFile = JoinDir(dir, a.PasswordFile)
156 a.UsernameFile = JoinDir(dir, a.UsernameFile)
157}
158
159// Authorization contains HTTP authorization credentials.
160type Authorization struct {

Callers

nothing calls this directly

Calls 1

JoinDirFunction · 0.85

Tested by

no test coverage detected