Add multipart for WASM (#966)

This commit is contained in:
Enno Boland
2020-07-08 22:10:23 +02:00
committed by GitHub
parent af9fc5c9d8
commit a800202384
7 changed files with 335 additions and 13 deletions

View File

@@ -190,6 +190,14 @@ impl RequestBuilder {
self
}
/// TODO
pub fn multipart(mut self, multipart: super::multipart::Form) -> RequestBuilder {
if let Ok(ref mut req) = self.request {
*req.body_mut() = Some(Body::from_form(multipart))
}
self
}
/// Add a `Header` to this Request.
pub fn header<K, V>(mut self, key: K, value: V) -> RequestBuilder
where