mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-25 06:34:42 +02:00
Fix error handling on config package delete
This commit is contained in:
parent
5e8321f3a4
commit
b53685db59
@ -135,12 +135,13 @@ void ConfigPackagesHandler::HandleDelete(const ApiUser::Ptr& user, HttpRequest&
|
|||||||
} catch (const std::exception& ex) {
|
} catch (const std::exception& ex) {
|
||||||
HttpUtility::SendJsonError(response, params, 500, "Failed to delete package '" + packageName + "'.",
|
HttpUtility::SendJsonError(response, params, 500, "Failed to delete package '" + packageName + "'.",
|
||||||
DiagnosticInformation(ex));
|
DiagnosticInformation(ex));
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
Dictionary::Ptr result1 = new Dictionary({
|
Dictionary::Ptr result1 = new Dictionary({
|
||||||
{ "code", 200 },
|
{ "code", 200 },
|
||||||
{ "package", packageName },
|
{ "package", packageName },
|
||||||
{ "status", "Created package." }
|
{ "status", "Deleted package." }
|
||||||
});
|
});
|
||||||
|
|
||||||
Dictionary::Ptr result = new Dictionary({
|
Dictionary::Ptr result = new Dictionary({
|
||||||
|
Loading…
x
Reference in New Issue
Block a user