fix(misspell): main
This commit is contained in:
parent
417b56a5c6
commit
5fd2c91b8c
4
main.go
4
main.go
|
@ -7,8 +7,8 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/knadh/koanf"
|
"github.com/knadh/koanf"
|
||||||
"github.com/knadh/koanf/parsers/toml"
|
|
||||||
"github.com/knadh/koanf/parsers/json"
|
"github.com/knadh/koanf/parsers/json"
|
||||||
|
"github.com/knadh/koanf/parsers/toml"
|
||||||
"github.com/knadh/koanf/parsers/yaml"
|
"github.com/knadh/koanf/parsers/yaml"
|
||||||
"github.com/knadh/koanf/providers/env"
|
"github.com/knadh/koanf/providers/env"
|
||||||
"github.com/knadh/koanf/providers/file"
|
"github.com/knadh/koanf/providers/file"
|
||||||
|
@ -48,7 +48,7 @@ func main() {
|
||||||
fileExt := filepath.Ext(configPath)
|
fileExt := filepath.Ext(configPath)
|
||||||
parser, ok := configExtParser[fileExt]
|
parser, ok := configExtParser[fileExt]
|
||||||
if !ok {
|
if !ok {
|
||||||
log.Panic("unsupported file extention:", zap.String("file-ext", fileExt))
|
log.Panic("unsupported file extension:", zap.String("file-ext", fileExt))
|
||||||
}
|
}
|
||||||
if err := k.Load(file.Provider(configPath), parser); err != nil {
|
if err := k.Load(file.Provider(configPath), parser); err != nil {
|
||||||
log.Panic("load file config:", zap.Error(err))
|
log.Panic("load file config:", zap.Error(err))
|
||||||
|
|
Loading…
Reference in New Issue