Struct cataclysm::http::Multipart [−][src]
pub struct Multipart { /* fields omitted */ }
Expand description
Multipart extractor
Meant to be used in functions to extract files from an http request
async fn receive_file(multipart: Multipart) -> Response {
for file in multipart.files() {
if let Some(filename) = &file.filename {
log::info!("Found file {}, writing content", filename);
// Do something with the file...
}
}
Response::ok()
}