filelist-fix
All checks were successful
deploy / deploy (push) Successful in 59s

This commit is contained in:
Untone 2024-10-22 12:30:27 +03:00
parent fd3f8371cc
commit 5784fb2283

View File

@ -96,10 +96,10 @@ pub async fn get_s3_filelist(client: &S3Client, bucket: &str) -> Vec<[std::strin
let mut parts = filepath.split('/').collect::<Vec<&str>>(); // Explicit type annotation
let filename = parts.pop().unwrap();
let mut filename_parts = filename.split('.').collect::<Vec<&str>>();
let _ext = filename_parts.pop().unwrap();
let filekey = filename_parts.pop().unwrap();
filekeys.push([filekey.to_string(), s3_filepath.to_string()]);
let _ext = filename_parts.pop().unwrap_or_default();
if let Some(filekey) = filename_parts.pop() {
filekeys.push([filekey.to_string(), s3_filepath.to_string()]);
}
}
}
}