The current implementation of the FileProtocol's file listing logic supports receiving a FileFilter but does not actually apply any filtering to the returned files.
Sending a massive file list as a single message may cause significant network overhead. The depth parameter in FileFilter is essential to limit the traversal and payload size, helping to mitigate this issue
|
let files = if let Some(filter) = filter { |
|
let uploaded_files = this.get_files_tree(filter.depth).await?; |
|
// TODO implement filtering logic |
|
uploaded_files |
|
} else { |
The current implementation of the FileProtocol's file listing logic supports receiving a FileFilter but does not actually apply any filtering to the returned files.
Sending a massive file list as a single message may cause significant network overhead. The depth parameter in FileFilter is essential to limit the traversal and payload size, helping to mitigate this issue
hermes/peer/src-tauri/src/network/protocol.rs
Lines 107 to 111 in 1690682