Map method string to httpd_method_t
| 643 | |
| 644 | // Map method string to httpd_method_t |
| 645 | httpd_method_t to_httpd_method(const string& method) { |
| 646 | if (method == "GET") return HTTP_GET; |
| 647 | if (method == "POST") return HTTP_POST; |
| 648 | if (method == "PUT") return HTTP_PUT; |
| 649 | if (method == "DELETE") return HTTP_DELETE; |
| 650 | return HTTP_GET; |
| 651 | } |
| 652 | |
| 653 | // Context passed to ESP-IDF URI handler callback |
| 654 | struct EspRouteContext { |