mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2026-02-18 06:10:53 +08:00
整理解析器
This commit is contained in:
@@ -154,7 +154,7 @@ static inline void addHttpListener(){
|
||||
val["code"] = API::Success;
|
||||
HttpSession::KeyValue headerOut;
|
||||
auto allArgs = getAllArgs(parser);
|
||||
HttpSession::KeyValue &headerIn = parser.getValues();
|
||||
HttpSession::KeyValue &headerIn = parser.getHeader();
|
||||
GET_CONFIG(string,charSet,Http::kCharSet);
|
||||
headerOut["Content-Type"] = StrPrinter << "application/json; charset=" << charSet;
|
||||
if(api_debug){
|
||||
|
||||
@@ -444,7 +444,7 @@ void installWebHook(){
|
||||
body["path"] = path;
|
||||
body["is_dir"] = is_dir;
|
||||
body["params"] = parser.Params();
|
||||
for(auto &pr : parser.getValues()){
|
||||
for(auto &pr : parser.getHeader()){
|
||||
body[string("header.") + pr.first] = pr.second;
|
||||
}
|
||||
//执行hook
|
||||
|
||||
Reference in New Issue
Block a user