mirror of https://github.com/Icinga/icinga2.git
Merge pull request #5804 from Icinga/fix/update-repository-message-error
Silence UpdateRepository message errors
This commit is contained in:
commit
8e65aa0677
|
@ -208,11 +208,12 @@ void JsonRpcConnection::MessageHandler(const String& jsonString)
|
||||||
try {
|
try {
|
||||||
ApiFunction::Ptr afunc = ApiFunction::GetByName(method);
|
ApiFunction::Ptr afunc = ApiFunction::GetByName(method);
|
||||||
|
|
||||||
if (!afunc)
|
if (!afunc) {
|
||||||
Log(LogWarning, "JsonRpcConnection")
|
Log(LogNotice, "JsonRpcConnection")
|
||||||
<< "Call to non-existent function '" << method << "' from endpoint '" << m_Identity << "'.";
|
<< "Call to non-existent function '" << method << "' from endpoint '" << m_Identity << "'.";
|
||||||
else
|
} else {
|
||||||
resultMessage->Set("result", afunc->Invoke(origin, message->Get("params")));
|
resultMessage->Set("result", afunc->Invoke(origin, message->Get("params")));
|
||||||
|
}
|
||||||
} catch (const std::exception& ex) {
|
} catch (const std::exception& ex) {
|
||||||
/* TODO: Add a user readable error message for the remote caller */
|
/* TODO: Add a user readable error message for the remote caller */
|
||||||
String diagInfo = DiagnosticInformation(ex);
|
String diagInfo = DiagnosticInformation(ex);
|
||||||
|
|
Loading…
Reference in New Issue