mirror of
https://github.com/spf13/viper
synced 2025-06-14 15:17:19 +00:00
Compare commits
1 commit
Author | SHA1 | Date | |
---|---|---|---|
|
a1b8372762 |
1 changed files with 3 additions and 1 deletions
4
viper.go
4
viper.go
|
@ -289,7 +289,9 @@ func (v *Viper) WatchConfig() {
|
|||
if err != nil {
|
||||
log.Println("error:", err)
|
||||
}
|
||||
v.onConfigChange(event)
|
||||
if v.onConfigChange != nil {
|
||||
v.onConfigChange(event)
|
||||
}
|
||||
}
|
||||
}
|
||||
case err := <-watcher.Errors:
|
||||
|
|
Loading…
Add table
Reference in a new issue