All checks were successful
tests / build (push) Successful in 1m4s
tests / fmt (push) Successful in 2m17s
tests / clippy (push) Successful in 2m14s
tests / pre-commit (push) Successful in 2m12s
tests / test (push) Successful in 2m27s
deploy / release-image (push) Successful in 6m11s
13 lines
315 B
Rust
13 lines
315 B
Rust
use futures::Future;
|
|
use std::error::Error;
|
|
|
|
pub(crate) fn spawn(
|
|
fut: impl Future<Output = Result<(), Box<dyn Error + Send + Sync + 'static>>> + Send + 'static,
|
|
) {
|
|
tokio::spawn(async move {
|
|
if let Err(why) = fut.await {
|
|
tracing::debug!("handler error: {:?}", why);
|
|
}
|
|
});
|
|
}
|