Fix indentation in README.md

See #345
This commit is contained in:
Albert Nigmatzianov 2017-07-23 06:54:24 +02:00 committed by Anthony Fok
parent df7314a14e
commit 16a9458573
1 changed files with 4 additions and 4 deletions

View File

@ -116,10 +116,10 @@ Optionally you can provide a function for Viper to run each time a change occurs
**Make sure you add all of the configPaths prior to calling `WatchConfig()`**
```go
viper.WatchConfig()
viper.OnConfigChange(func(e fsnotify.Event) {
viper.WatchConfig()
viper.OnConfigChange(func(e fsnotify.Event) {
fmt.Println("Config file changed:", e.Name)
})
})
```
### Reading Config from io.Reader