We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad9f8b6 commit 89bb824Copy full SHA for 89bb824
crates/web-ui/src/handlers.rs
@@ -868,6 +868,7 @@ pub async fn search_files(
868
869
use chrono::{DateTime, Utc};
870
use std::fs;
871
+#[cfg(unix)]
872
use std::os::unix::fs::PermissionsExt;
873
use std::path::Path;
874
@@ -1001,10 +1002,13 @@ fn collect_entries_single_level(
1001
1002
});
1003
1004
let mut entry_metadata = HashMap::new();
1005
+ #[cfg(unix)]
1006
entry_metadata.insert(
1007
"permissions".to_string(),
1008
json!(format!("{:o}", metadata.permissions().mode() & 0o777)),
1009
);
1010
+ #[cfg(not(unix))]
1011
+ entry_metadata.insert("permissions".to_string(), json!("N/A"));
1012
1013
entries.push(FileSystemEntry {
1014
path: path.to_string_lossy().to_string(),
0 commit comments