This commit is contained in:
parent
5b33e4a566
commit
bcd66e798a
|
@ -129,11 +129,15 @@ pub async fn proxy_handler(
|
|||
|
||||
// весь запрошенный путь
|
||||
let requested_path = match state.get_path(&path).await {
|
||||
Some(Some(path)) => path,
|
||||
_ => {
|
||||
Ok(Some(path)) => path,
|
||||
Ok(None) => {
|
||||
warn!("Путь не найден: {}", path);
|
||||
return Ok(HttpResponse::NotFound().finish());
|
||||
}
|
||||
Err(e) => {
|
||||
warn!("Ошибка: {}", e);
|
||||
return Ok(HttpResponse::InternalServerError().finish());
|
||||
}
|
||||
};
|
||||
info!("Запрошенный путь: {}", requested_path);
|
||||
|
||||
|
@ -157,7 +161,7 @@ pub async fn proxy_handler(
|
|||
// Находим ближайший подходящий размер
|
||||
let closest_width = find_closest_width(requested_width);
|
||||
let thumbnail_key = format!("{}_{}", base_filename, closest_width);
|
||||
info!("Ближайшая ширина: {}, Ключ миниатюры: {}", closest_width, thumbnail_key);
|
||||
info!("Ближайшая ширина: {}, Кюч миниатюры: {}", closest_width, thumbnail_key);
|
||||
|
||||
// Проверяем наличие миниатюры в кэше
|
||||
let cached_files = state.get_cached_file_list().await;
|
||||
|
|
Loading…
Reference in New Issue
Block a user