Fix insecure extension check in read_sheet_file and run cargo fmt

Co-authored-by: Horizontal42 <75383519+Horizontal42@users.noreply.github.com>
This commit is contained in:
google-labs-jules[bot] 2026-10-07 04:12:49 +00:00
parent 5b115d27f7
commit f65806403a

View file

@ -938,12 +938,10 @@ fn load_extensions(app: AppHandle) -> Vec<ExtensionScript> {
}
fn is_sheet_path(path: &str) -> bool {
std::path::Path::new(path)
.extension()
.map_or(false, |ext| {
let ext = ext.to_string_lossy().to_lowercase();
ext == "numi" || ext == "sum"
})
std::path::Path::new(path).extension().map_or(false, |ext| {
let ext = ext.to_string_lossy().to_lowercase();
ext == "numi" || ext == "sum"
})
}
/// A sheet handed to us by the OS (file association, second launch): same