update %s to %w

I apologize for my rude pr on modify readme
I think it is better to use %w in fmt.Errorf instead of %s
(see go doc)[https://golang.org/pkg/errors/]
This commit is contained in:
lmx-Hexagram 2021-04-07 09:35:18 +08:00 committed by GitHub
parent 52536944d5
commit 423bb04d36
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -119,7 +119,7 @@ viper.AddConfigPath("$HOME/.appname") // call multiple times to add many search
viper.AddConfigPath(".") // optionally look for config in the working directory
err := viper.ReadInConfig() // Find and read the config file
if err != nil { // Handle errors reading the config file
panic(fmt.Errorf("Fatal error config file: %s \n", err))
panic(fmt.Errorf("Fatal error config file: %w \n", err))
}
```