mirror of
https://github.com/esphome/esphome.git
synced 2025-09-08 14:22:21 +01:00
beginResponse_P
This commit is contained in:
@@ -205,7 +205,7 @@ void OTARequestHandler::handleRequest(AsyncWebServerRequest *request) {
|
|||||||
static const char CONNECTION_STR[] PROGMEM = "Connection";
|
static const char CONNECTION_STR[] PROGMEM = "Connection";
|
||||||
static const char CLOSE_STR[] PROGMEM = "close";
|
static const char CLOSE_STR[] PROGMEM = "close";
|
||||||
const char *msg = this->ota_success_ ? UPDATE_SUCCESS : UPDATE_FAILED;
|
const char *msg = this->ota_success_ ? UPDATE_SUCCESS : UPDATE_FAILED;
|
||||||
response = request->beginResponse(200, TEXT_PLAIN, msg);
|
response = request->beginResponse_P(200, TEXT_PLAIN, msg);
|
||||||
response->addHeader(CONNECTION_STR, CLOSE_STR);
|
response->addHeader(CONNECTION_STR, CLOSE_STR);
|
||||||
#else
|
#else
|
||||||
const char *msg = this->ota_success_ ? "Update Successful!" : "Update Failed!";
|
const char *msg = this->ota_success_ ? "Update Successful!" : "Update Failed!";
|
||||||
|
Reference in New Issue
Block a user