MCPcopy
hub / github.com/gourouting/singo / envDefault

Function envDefault

conf/conf.go:17–22  ·  view source on GitHub ↗
(key, fallback string)

Source from the content-addressed store, hash-verified

15)
16
17func envDefault(key, fallback string) string {
18 if value := os.Getenv(key); value != "" {
19 return value
20 }
21 return fallback
22}
23
24func validateDSNPart(name, value string, reserved ...string) error {
25 for _, char := range reserved {

Callers 1

DatabaseDSNFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected