| 542 | } |
| 543 | |
| 544 | fl::task::Promise<Response> fetch_put(const fl::string& url, const FetchOptions& request) { |
| 545 | // Create a new request with PUT method |
| 546 | FetchOptions put_request(url, RequestOptions("PUT")); |
| 547 | |
| 548 | // Apply any additional options from the provided request |
| 549 | const auto& opts = request.options(); |
| 550 | put_request.timeout(opts.timeout_ms); |
| 551 | for (const auto& header : opts.headers) { |
| 552 | put_request.header(header.first, header.second); |
| 553 | } |
| 554 | if (!opts.body.empty()) { |
| 555 | put_request.body(opts.body); |
| 556 | } |
| 557 | |
| 558 | return execute_fetch_request(url, put_request); |
| 559 | } |
| 560 | |
| 561 | fl::task::Promise<Response> fetch_delete(const fl::string& url, const FetchOptions& request) { |
| 562 | // Create a new request with DELETE method |
nothing calls this directly
no test coverage detected