fixed visibility of structs.

This commit is contained in:
Pradyumna Kaushik 2019-12-05 23:02:08 -05:00
parent f084eddd68
commit 5a53998942
9 changed files with 61 additions and 61 deletions

View file

@ -7,7 +7,7 @@ import (
"io/ioutil"
)
type LoggerConfig struct {
type loggerConfig struct {
SchedTraceConfig struct {
Enabled bool `yaml:"enabled"`
FilenameExtension string `yaml:"filenameExtension"`
@ -48,14 +48,14 @@ type LoggerConfig struct {
Format []string `yaml:"format"`
}
func GetConfig(logConfigFilename string) (*LoggerConfig, error) {
func GetConfig(logConfigFilename string) (*loggerConfig, error) {
yamlFile, err := ioutil.ReadFile(logConfigFilename)
if err != nil {
return nil, errors.Wrap(err, "failed to read log config file")
}
c := &LoggerConfig{}
c := &loggerConfig{}
err = yaml.Unmarshal(yamlFile, c)
if err != nil {
log.Fatalf("Error in unmarshalling yaml: %v", err)