fix symlink not traversing

This commit is contained in:
slonkazoid 2024-12-24 23:55:51 +03:00
parent 8a05a21bb5
commit 4cecaa7579
Signed by: slonk
SSH key fingerprint: SHA256:tbZfJX4IOvZ0LGWOWu5Ijo8jfMPi78TU7x1VoEeCIjM

View file

@ -168,8 +168,9 @@ impl PostManager for Blag {
}
};
let file_type = entry.file_type().await?;
if file_type.is_file() {
let stat = tokio::fs::metadata(entry.path()).await?;
if stat.file_type().is_file() {
let mut name = match entry.file_name().into_string() {
Ok(v) => v,
Err(_) => {