Accept multiple HTTP methods.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos
2026-04-26 18:00:29 +02:00
parent a906628318
commit c8b5bf8f82
3 changed files with 22 additions and 5 deletions

View File

@@ -698,7 +698,7 @@ void rest_handle_request(rest_conn_t *conn) {
if (strcmp(routes[i].path, request->path) != 0) {
continue;
}
if (routes[i].method != request->method) {
if (!(routes[i].method & request->method)) {
path_exists_for_other_method = true;
continue;
}