Merge pull request #473 from unpoller/datadog-output-npe-3

bugfix: datadog NPE
This commit is contained in:
Cody Lee 2022-12-20 20:14:39 -06:00 committed by GitHub
commit a0feffb4f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -194,7 +194,10 @@ func (u *DatadogUnifi) Enabled() bool {
if u == nil { if u == nil {
return false return false
} }
if u.Enable == nil || u.Config == nil { if u.Config == nil {
return false
}
if u.Enable == nil {
return false return false
} }
return *u.Enable return *u.Enable