forked from me-no-dev/ESPAsyncWebServer
Add support for Content-Type with charset (#561)
This commit is contained in:
@@ -316,13 +316,11 @@ bool AsyncWebServerRequest::_parseReqHeader(){
|
||||
if(name.equalsIgnoreCase("Host")){
|
||||
_host = value;
|
||||
} else if(name.equalsIgnoreCase("Content-Type")){
|
||||
_contentType = value.substring(0, value.indexOf(';'));
|
||||
if (value.startsWith("multipart/")){
|
||||
_boundary = value.substring(value.indexOf('=')+1);
|
||||
_boundary.replace("\"","");
|
||||
_contentType = value.substring(0, value.indexOf(';'));
|
||||
_isMultipart = true;
|
||||
} else {
|
||||
_contentType = value;
|
||||
}
|
||||
} else if(name.equalsIgnoreCase("Content-Length")){
|
||||
_contentLength = atoi(value.c_str());
|
||||
|
Reference in New Issue
Block a user