diff --git a/lib/icinga/checkable.cpp b/lib/icinga/checkable.cpp index 75e23c03d..0f4d1399b 100644 --- a/lib/icinga/checkable.cpp +++ b/lib/icinga/checkable.cpp @@ -143,15 +143,7 @@ void Checkable::ClearAcknowledgement(const String& removedBy, double changeTime, { ObjectLock oLock (this); - bool wasAcked; - - if (GetAcknowledgementRaw() == AcknowledgementNone) { - wasAcked = false; - } else { - double expiry = GetAcknowledgementExpiry(); - - wasAcked = expiry == 0 || expiry >= Utility::GetTime(); - } + bool wasAcked = GetAcknowledgementRaw() != AcknowledgementNone; SetAcknowledgementRaw(AcknowledgementNone); SetAcknowledgementExpiry(0);