docs
Some checks failed
CI / test (push) Failing after 4m0s
CI / lint (push) Failing after 4s
CI / deploy (push) Has been skipped

This commit is contained in:
2025-08-02 00:18:09 +03:00
parent adda2b30f9
commit ea92a376ed
32 changed files with 3360 additions and 280 deletions

View File

@@ -1,8 +1,8 @@
use std::collections::HashMap;
use actix_web::error::ErrorInternalServerError;
use once_cell::sync::Lazy;
use redis::aio::MultiplexedConnection;
use redis::AsyncCommands;
use std::collections::HashMap;
pub static MIME_TYPES: Lazy<HashMap<&'static str, &'static str>> = Lazy::new(|| {
let mut m = HashMap::new();
@@ -36,7 +36,6 @@ pub fn get_mime_type(extension: &str) -> Option<&'static str> {
MIME_TYPES.get(extension).copied()
}
/// Ищет файл в Redis по шаблону имени
pub async fn find_file_by_pattern(
redis: &mut MultiplexedConnection,
@@ -67,4 +66,4 @@ pub async fn store_file_info(
.await
.map_err(|_| ErrorInternalServerError("Failed to store file info in Redis"))?;
Ok(())
}
}