mirror of https://github.com/Icinga/icinga2.git
ConfigObjectUtility::DeleteObjectHelper(): only delete _api files
to restore the behavior before the previous commit. Otherwise we'd delete all API object's child objects' files including applied child object rules in /etc.
This commit is contained in:
parent
145ee890df
commit
e1bb085b0f
|
@ -353,7 +353,9 @@ bool ConfigObjectUtility::DeleteObjectHelper(const ConfigObject::Ptr& object, bo
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
Utility::Remove(GetExistingObjectConfigPath(object));
|
if (object->GetPackage() == "_api") {
|
||||||
|
Utility::Remove(GetExistingObjectConfigPath(object));
|
||||||
|
}
|
||||||
|
|
||||||
Log(LogInformation, "ConfigObjectUtility")
|
Log(LogInformation, "ConfigObjectUtility")
|
||||||
<< "Deleted object '" << name << "' of type '" << type->GetName() << "'.";
|
<< "Deleted object '" << name << "' of type '" << type->GetName() << "'.";
|
||||||
|
|
Loading…
Reference in New Issue