diff --git a/lib/icinga/downtime.cpp b/lib/icinga/downtime.cpp index 909ba7e8f..f2fbc8419 100644 --- a/lib/icinga/downtime.cpp +++ b/lib/icinga/downtime.cpp @@ -134,7 +134,7 @@ void Downtime::Start(bool runtimeCreated) * this downtime now *after* it has been added (important * for DB IDO, etc.) */ - if (checkable->GetStateRaw() != ServiceOK) { + if (!checkable->IsStateOK(checkable->GetStateRaw())) { Log(LogNotice, "Downtime") << "Checkable '" << checkable->GetName() << "' already in a NOT-OK state." << " Triggering downtime now.";