mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-03-21 17:34:57 -05:00
Log HTTP errors when verbose logging is enabled
This commit is contained in:
parent
8326e72047
commit
470d5ba3d7
|
|
@ -102,6 +102,11 @@ bool MacroActionHttp::PerformAction()
|
|||
break;
|
||||
}
|
||||
|
||||
if (VerboseLoggingEnabled() && !response) {
|
||||
blog(LOG_INFO, "HTTP action error: %s",
|
||||
httplib::to_string(response.error()).c_str());
|
||||
}
|
||||
|
||||
SetTempVarValue("status",
|
||||
response ? std::to_string(response->status) : "");
|
||||
SetTempVarValue("body", response ? response->body : "");
|
||||
|
|
@ -140,6 +145,7 @@ static std::string stringListToString(const StringList &list)
|
|||
result += std::string(string) + ", ";
|
||||
}
|
||||
result.pop_back();
|
||||
result.pop_back();
|
||||
return result + "]";
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user