Comments.
Coverage to Makefile.toml. Added branch to map! to allow for instantiating with default values.
This commit is contained in:
@ -1,5 +1,10 @@
|
||||
use {std::io::Error, tokio::fs::File, tokio_util::io::ReaderStream};
|
||||
|
||||
/// Loads a file from the file system and returns a stream of bytes.
|
||||
/// # Arguments
|
||||
/// * `file_path` - The path to the file to load.
|
||||
/// # Returns
|
||||
/// A stream of bytes from the file if the file is found. Otherwise, an error is returned.
|
||||
pub async fn load_file<Path>(file_path: Path) -> Result<ReaderStream<File>, Error>
|
||||
where
|
||||
Path: AsRef<std::path::Path>,
|
||||
|
Reference in New Issue
Block a user