web_server_idf: fix call with hardcoded http code (#5942)

This commit is contained in:
dentra 2023-12-18 03:01:21 +03:00 committed by Jesse Hills
parent e8ce780482
commit d0df73769d
No known key found for this signature in database
GPG Key ID: BEAAE804EFD8E83A

View File

@ -117,7 +117,7 @@ class AsyncWebServerRequest {
// NOLINTNEXTLINE(readability-identifier-naming)
AsyncWebServerResponse *beginResponse(int code, const char *content_type) {
auto *res = new AsyncWebServerResponseEmpty(this); // NOLINT(cppcoreguidelines-owning-memory)
this->init_response_(res, 200, content_type);
this->init_response_(res, code, content_type);
return res;
}
// NOLINTNEXTLINE(readability-identifier-naming)