Skip to content

Commit

Permalink
adjust imports
Browse files Browse the repository at this point in the history
  • Loading branch information
thebino committed Oct 27, 2023
1 parent c54261f commit f683903
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 12 deletions.
5 changes: 1 addition & 4 deletions crates/media/src/api/routes/post_media.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,10 @@
use axum::{
extract::{Multipart, State},
http::StatusCode,
response::{IntoResponse, Redirect, Response},
response::{IntoResponse, Redirect},
Json,
};
use common::auth::user::User;
use hyper::header::LOCATION;
use hyper::HeaderMap;
use serde::{Deserialize, Serialize};
use time::format_description::well_known::Rfc3339;
use time::OffsetDateTime;
Expand All @@ -48,7 +46,6 @@ pub(crate) async fn post_media(

let mut name = None;
let mut date_taken = None;
let mut headers = HeaderMap::new();

while let Some(field) = multipart.next_field().await.unwrap() {
if let Some(field_name) = field.name() {
Expand Down
5 changes: 0 additions & 5 deletions crates/media/src/api/routes/post_media_id.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,10 @@
//! Add files for a specific media item
//!

use core::panic;

use axum::extract::{Multipart, Path, State};
use axum::http::StatusCode;
use axum::response::{IntoResponse, Redirect};
use common::auth::user::User;
use hyper::header::LOCATION;
use hyper::HeaderMap;
use tempfile::tempfile;
use tracing::{debug, info};
use uuid::Uuid;

Expand Down
3 changes: 0 additions & 3 deletions crates/media/src/repository.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,11 @@ use bytes::Bytes;
use common::config::configuration::Configuration;
use common::database::reference::Reference;
use common::database::Database;
use core::ffi::FromBytesUntilNulError;
use database::sqlite::SqliteDatabase;
use std::fs;
use std::path::Path;
use std::sync::Arc;
use time::OffsetDateTime;
use tokio::fs::File;
use tokio::io::AsyncWriteExt;
use tracing::log::warn;
use tracing::{debug, info};
use uuid::Uuid;
Expand Down

0 comments on commit f683903

Please sign in to comment.