mirror of
https://github.com/spf13/viper
synced 2025-05-11 06:37:27 +00:00
go fmt
This commit is contained in:
parent
f9a856a8eb
commit
b8bc81dfc7
1 changed files with 2 additions and 2 deletions
4
viper.go
4
viper.go
|
@ -1775,7 +1775,7 @@ func (v *Viper) watchKeyValueConfigOnChannel() error {
|
|||
for {
|
||||
b := <-rc
|
||||
reader := bytes.NewReader(b.Value)
|
||||
kvstore := make(map[string]interface{},len(v.kvstore))
|
||||
kvstore := make(map[string]interface{}, len(v.kvstore))
|
||||
v.unmarshalReader(reader, kvstore)
|
||||
v.kvstore = kvstore
|
||||
}
|
||||
|
@ -1803,7 +1803,7 @@ func (v *Viper) watchRemoteConfig(provider RemoteProvider) (map[string]interface
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
kvstore := make(map[string]interface{},len(v.kvstore))
|
||||
kvstore := make(map[string]interface{}, len(v.kvstore))
|
||||
err = v.unmarshalReader(reader, kvstore)
|
||||
return kvstore, err
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue