Skip to content

Commit

Permalink
fix empty config error
Browse files Browse the repository at this point in the history
  • Loading branch information
cenkalti committed Sep 9, 2020
1 parent 4a26a63 commit 0b7cce3
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions cmd/putio-sync/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,7 @@ func main() {

viper.AutomaticEnv()
err := viper.ReadInConfig()
if _, ok := err.(viper.ConfigFileNotFoundError); ok {
err = nil
}
if err != nil {
if err != nil && !os.IsNotExist(err) {
log.Fatal(err)
}
setConfigValues()
Expand Down

0 comments on commit 0b7cce3

Please sign in to comment.