From 47a1b62fce314d5933e828fc5e5087d723afe91f Mon Sep 17 00:00:00 2001 From: Frank <91616163+softhack007@users.noreply.github.com> Date: Sun, 30 Nov 2025 14:10:33 +0100 Subject: [PATCH] tiny optimization small flash optimization by re-using string constants (string merging) --- wled00/wled_server.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wled00/wled_server.cpp b/wled00/wled_server.cpp index 912428cf..5e6eb4b2 100644 --- a/wled00/wled_server.cpp +++ b/wled00/wled_server.cpp @@ -17,8 +17,8 @@ static const char s_content_enc[] PROGMEM = "Content-Encoding"; static const char s_unlock_ota [] PROGMEM = "Please unlock OTA in security settings!"; static const char s_unlock_cfg [] PROGMEM = "Please unlock settings using PIN code!"; static const char s_cache_control[] PROGMEM = "Cache-Control"; -static const char s_no_store[] PROGMEM = "no-store"; -static const char s_expires[] PROGMEM = "Expires"; +//static const char s_no_store[] PROGMEM = "no-store"; +//static const char s_expires[] PROGMEM = "Expires"; /* * Integrated HTTP web server page declarations @@ -619,7 +619,7 @@ void serveSettingsJS(AsyncWebServerRequest* request) AsyncWebServerResponse *response; response = request->beginResponse(200, "application/javascript", buf); - response->addHeader(F("Cache-Control"),"no-store"); + response->addHeader(FPSTR(s_cache_control),F("no-store")); response->addHeader(F("Expires"),"0"); request->send(response); }