Skip to content

Commit

Permalink
remove loggly check, due to default
Browse files Browse the repository at this point in the history
  • Loading branch information
ire-and-curses committed Jan 28, 2019
1 parent 96cabe7 commit 95b4907
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions services/horizon/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,9 +156,9 @@ func validateBothOrNeither(option1, option2 string) {
arg1, arg2 := viper.GetString(option1), viper.GetString(option2)
switch {
case arg1 != "" && arg2 == "":
stdLog.Fatalf("Invalid config: %s=%s, but %s is not configured", option1, arg1, option2)
stdLog.Fatalf("Invalid config: %s = %s, but corresponding option %s is not configured", option1, arg1, option2)
case arg1 == "" && arg2 != "":
stdLog.Fatalf("Invalid config: %s=%s, but %s is not configured", option2, arg2, option1)
stdLog.Fatalf("Invalid config: %s = %s, but corresponding option %s is not configured", option2, arg2, option1)
}
}

Expand All @@ -180,7 +180,8 @@ func checkMigrations() {
}
}

// configOpts defines the complete flag configuration for horizon. Add a new line here to connect a new field in the horizon.Config struct
// configOpts defines the complete flag configuration for horizon
// Add a new entry here to connect a new field in the horizon.Config struct
var configOpts = []*configOption{
&configOption{
name: "db-url",
Expand Down Expand Up @@ -396,7 +397,6 @@ func initConfig() {
}
// Validate options that should be provided together
validateBothOrNeither("tls-cert", "tls-key")
validateBothOrNeither("loggly-token", "loggly-tag")
validateBothOrNeither("rate-limit-redis-key", "redis-url")

// Configure log file
Expand All @@ -411,5 +411,4 @@ func initConfig() {

// Configure log level
log.DefaultLogger.Level = config.LogLevel
stdLog.Fatal(config)
}

0 comments on commit 95b4907

Please sign in to comment.