Fix statsd initialization

This commit is contained in:
ErickSkrauch 2020-04-20 19:03:47 +03:00
parent 440b505306
commit 5862d1cbf6
No known key found for this signature in database
GPG Key ID: 669339FCBB30EE0E

View File

@ -75,7 +75,7 @@ func newStatsReporter(config *viper.Viper) (slf.StatsReporter, error) {
dispatcher := &slf.Dispatcher{}
statsdAddr := config.GetString("statsd.addr")
if statsdAddr == "" {
if statsdAddr != "" {
hostname, err := os.Hostname()
if err != nil {
return nil, err