✨ Updated dependencies, nix shell, justfile
- Updated all dependencies - Updated Rust edition to 2024 - Nix shell from flake - Added justfile - Mirgrate all changes to various packages
This commit is contained in:
@ -1,8 +1,7 @@
|
||||
use axum::{
|
||||
async_trait,
|
||||
extract::{
|
||||
multipart::{Field, MultipartError, MultipartRejection},
|
||||
FromRequest, Multipart, Request,
|
||||
multipart::{Field, MultipartError, MultipartRejection},
|
||||
},
|
||||
response::IntoResponse,
|
||||
};
|
||||
@ -110,7 +109,6 @@ impl IntoResponse for MultipartFileRejection {
|
||||
}
|
||||
}
|
||||
|
||||
#[async_trait]
|
||||
impl<S> FromRequest<S> for MultipartFile
|
||||
where
|
||||
S: Send + Sync,
|
||||
@ -142,7 +140,6 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
#[async_trait]
|
||||
impl<S> FromRequest<S> for MultipartFiles
|
||||
where
|
||||
S: Send + Sync,
|
||||
@ -178,7 +175,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
async fn get_files<'a>(mut multipart: Multipart) -> Result<Vec<File>, MultipartFileRejection> {
|
||||
async fn get_files(mut multipart: Multipart) -> Result<Vec<File>, MultipartFileRejection> {
|
||||
let mut files = vec![];
|
||||
while let Some(field) = multipart.next_field().await? {
|
||||
files.push(File::from_field(field).await?);
|
||||
|
Reference in New Issue
Block a user