Fix CORS for /health endpoint
This commit is contained in:
parent
784e11dea1
commit
0e51cc38cb
1 changed files with 1 additions and 0 deletions
|
@ -3110,6 +3110,7 @@ int main(int argc, char ** argv) {
|
|||
//
|
||||
|
||||
const auto handle_health = [&](const httplib::Request & req, httplib::Response & res) {
|
||||
res.set_header("Access-Control-Allow-Origin", req.get_header_value("Origin"));
|
||||
server_state current_state = state.load();
|
||||
switch (current_state) {
|
||||
case SERVER_STATE_READY:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue