mirror of
https://github.com/esp8266/Arduino.git
synced 2025-07-26 07:02:15 +03:00
small addons (#5847)
* make (static) ESP8266WebServer::responseCodeToString visible and usable * esp8266:coreVersionNumeric(): add a define and comment-example to check on its usability
This commit is contained in:
@ -371,7 +371,7 @@ void ESP8266WebServer::_prepareHeader(String& response, int code, const char* co
|
||||
response = String(F("HTTP/1.")) + String(_currentVersion) + ' ';
|
||||
response += String(code);
|
||||
response += ' ';
|
||||
response += _responseCodeToString(code);
|
||||
response += responseCodeToString(code);
|
||||
response += "\r\n";
|
||||
|
||||
using namespace mime;
|
||||
@ -625,7 +625,7 @@ void ESP8266WebServer::_finalizeResponse() {
|
||||
}
|
||||
}
|
||||
|
||||
const String ESP8266WebServer::_responseCodeToString(int code) {
|
||||
const String ESP8266WebServer::responseCodeToString(const int code) {
|
||||
switch (code) {
|
||||
case 100: return F("Continue");
|
||||
case 101: return F("Switching Protocols");
|
||||
|
Reference in New Issue
Block a user