mirror of
https://github.com/MetaCubeX/subconverter.git
synced 2025-11-04 18:19:42 +08:00
Add CORS header to httplib webserver
This commit is contained in:
parent
05910ac5dd
commit
3f5ed82672
@ -170,6 +170,7 @@ int WebServer::start_web_server_multi(listener_args *args)
|
||||
{
|
||||
res.set_header("Access-Control-Allow-Headers", req.get_header_value("Access-Control-Request-Headers"));
|
||||
}
|
||||
res.set_header("Access-Control-Allow-Origin", "*");
|
||||
return httplib::Server::HandlerResponse::Unhandled;
|
||||
});
|
||||
for (auto &x : redirect_map)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user