Merge pull request #7890 from Icinga/bugfix/icingadb-flapping-history-more-ends-than-starts-7885

Fire Checkable::OnFlappingChange only if flapping is enabled
This commit is contained in:
Noah Hilverling 2020-03-05 09:36:57 +01:00 committed by GitHub
commit 2c467bbfef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -70,7 +70,9 @@ void Checkable::UpdateFlappingStatus(bool stateChange)
double ee = GetLastCheckResult()->GetExecutionEnd();
OnFlappingChange(this, ee);
if (GetEnableFlapping() && IcingaApplication::GetInstance()->GetEnableFlapping()) {
OnFlappingChange(this, ee);
}
SetFlappingLastChange(ee);
}