Skip to main content

resolve_direct_asset

Function resolve_direct_asset 

Source
pub fn resolve_direct_asset(
    root: &Path,
    path: &str,
) -> Result<Option<(PathBuf, &'static str)>, ()>
Expand description

Resolves a direct /static/ or /media/ request under an artifact root.

§Parameters

§Returns

Returns the successful value produced by crate::artifact_server::resolve_direct_asset or an error when the operation fails.

§Errors

Returns an error value when crate::artifact_server::resolve_direct_asset cannot complete successfully.

§Examples

ⓘ
let _result = pharos_runtime_static::artifact_server::resolve_direct_asset(std::path::Path::new("."), std::path::Path::new("fixture.json"), todo!());