mirror of
https://github.com/Icinga/icinga2.git
synced 2025-09-23 17:57:54 +02:00
Allow apiactions to return sucecss http codes different from 200
This commit is contained in:
parent
b3a504bc9c
commit
8bd829b4ae
@ -94,7 +94,7 @@ bool ActionsHandler::HandleRequest(
|
|||||||
int statusCode = 500;
|
int statusCode = 500;
|
||||||
|
|
||||||
for (const Dictionary::Ptr& res : results) {
|
for (const Dictionary::Ptr& res : results) {
|
||||||
if (res->Contains("code") && res->Get("code") == 200) {
|
if (res->Contains("code") && res->Get("code") >= 200 && res->Get("code") <= 299) {
|
||||||
statusCode = 200;
|
statusCode = 200;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user