fix usage of yanic dependencies

This commit is contained in:
genofire 2020-05-18 00:16:01 +02:00
parent 0bbee96ab7
commit d6ed86b82a
1 changed files with 5 additions and 1 deletions

View File

@ -72,7 +72,11 @@ func main() {
log.Printf("delaying %0.1f seconds", delay.Seconds())
time.Sleep(delay)
}
collector = respondYanic.NewCollector(yanic, nodesYanic, make(map[string][]string), []respondYanic.InterfaceConfig{config.Yanic})
collector = respondYanic.NewCollector(yanic, nodesYanic, &respondYanic.Config{
Enable: true,
Interfaces: []respondYanic.InterfaceConfig{config.Yanic},
Sites: make(map[string]respondYanic.SiteConfig),
})
if duration := config.YanicCollectInterval.Duration; duration > 0 {
collector.Start(config.YanicCollectInterval.Duration)
}