Error Handling for NewAgentConfig

This commit is contained in:
redanthrax 2022-08-19 10:56:56 -07:00
parent 89d7ec8242
commit 87c035cd39
3 changed files with 10 additions and 7 deletions

View file

@ -97,7 +97,10 @@ func New(logger *logrus.Logger, version string) *Agent {
pybin = filepath.Join(pd, "py38-x32", "python.exe")
}
ac := NewAgentConfig()
ac, err := NewAgentConfig()
if err != nil {
logger.Fatalln(err)
}
headers := make(map[string]string)
if len(ac.Token) > 0 {