From bfd31beb1c3c06a047fea933243513945620983a Mon Sep 17 00:00:00 2001 From: David Sankel Date: Wed, 14 Aug 2024 23:49:08 +0530 Subject: [PATCH] docs: Improve RequestBuilder::multipart's documentation (#2388) Making it clear that Content-Type is set will help prevent callers from building maleformed requests where that field is present multiple times. --- src/async_impl/request.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/async_impl/request.rs b/src/async_impl/request.rs index aa900ca02..76b40a788 100644 --- a/src/async_impl/request.rs +++ b/src/async_impl/request.rs @@ -309,6 +309,9 @@ impl RequestBuilder { /// # Ok(()) /// # } /// ``` + /// + /// In additional the request's body, the Content-Type and Content-Length fields are + /// appropriately set. #[cfg(feature = "multipart")] #[cfg_attr(docsrs, doc(cfg(feature = "multipart")))] pub fn multipart(self, mut multipart: multipart::Form) -> RequestBuilder {