1
0
Fork 0

Update linter

This commit is contained in:
Ludovic Fernandez 2020-05-11 12:06:07 +02:00 committed by GitHub
parent f12c27aa7c
commit 328611c619
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
157 changed files with 489 additions and 508 deletions

View file

@ -17,7 +17,7 @@ const DefaultNamePrefix = "TRAEFIK_"
// env vars -> map
// map -> tree of untyped nodes
// untyped nodes -> nodes augmented with metadata such as kind (inferred from element)
// "typed" nodes -> typed element
// "typed" nodes -> typed element.
func Decode(environ []string, prefix string, element interface{}) error {
if err := checkPrefix(prefix); err != nil {
return err
@ -40,7 +40,7 @@ func Decode(environ []string, prefix string, element interface{}) error {
// The operation goes through three stages roughly summarized as:
// typed configuration in element -> tree of untyped nodes
// untyped nodes -> nodes augmented with metadata such as kind (inferred from element)
// "typed" nodes -> environment variables with default values (determined by type/kind)
// "typed" nodes -> environment variables with default values (determined by type/kind).
func Encode(element interface{}) ([]parser.Flat, error) {
if element == nil {
return nil, nil