fix config declaration typo

Signed-off-by: Luca Bigliardi <shammash@google.com>
This commit is contained in:
Luca Bigliardi 2021-04-17 23:17:38 +02:00
parent a63bfa3aad
commit cace8c91fe

View File

@ -18,6 +18,8 @@ import (
"gopkg.in/yaml.v2"
"io/ioutil"
"os"
"github.com/google/alertmanager-irc-relay/logging"
)
const (
@ -47,7 +49,7 @@ type Config struct {
UsePrivmsg bool `yaml:"use_privmsg"`
AlertBufferSize int `yaml:"alert_buffer_size"`
NickservIdentifyPatterns []string `yaml:nickserv_identify_patterns`
NickservIdentifyPatterns []string `yaml:"nickserv_identify_patterns"`
}
func LoadConfig(configFile string) (*Config, error) {
@ -93,5 +95,8 @@ func LoadConfig(configFile string) (*Config, error) {
}
}
loadedConfig, _ := yaml.Marshal(config)
logging.Debug("Loaded config:\n%s", loadedConfig)
return config, nil
}