You've already forked oauth2-proxy
mirror of
https://github.com/oauth2-proxy/oauth2-proxy.git
synced 2025-06-19 00:27:39 +02:00
Add comments to exported methods for root package
This commit is contained in:
@ -6,8 +6,14 @@ import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
// EnvOptions holds program options loaded from the process environment
|
||||
type EnvOptions map[string]interface{}
|
||||
|
||||
// LoadEnvForStruct loads environment variables for each field in an options
|
||||
// struct passed into it.
|
||||
//
|
||||
// Fields in the options struct must have an `env` and `cfg` tag to be read
|
||||
// from the environment
|
||||
func (cfg EnvOptions) LoadEnvForStruct(options interface{}) {
|
||||
val := reflect.ValueOf(options).Elem()
|
||||
typ := val.Type()
|
||||
|
Reference in New Issue
Block a user