Skip to main content

with_service

Function with_service 

Source
pub async fn with_service<F, T, E>(
    svc: &'static str,
    fut: F,
) -> <F as Future>::Output
where F: Future<Output = Result<T, Error<E>>>, E: ErrorDiagnostic + Clone,
Expand description

Executes a future and ensures an error service is set.

If the error does not already have a service, the provided service is assigned.