feat: Serve never returns

This commit is contained in:
2026-10-04 03:06:45 +02:00
parent bd36d58911
commit 721ce459de
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
#![feature(path_absolute_method)]
#![feature(path_absolute_method, never_type)]
use std::path::{Path, PathBuf};
use std::sync::OnceLock;
+1 -1
View File
@@ -145,7 +145,7 @@ where
Ok(())
}
pub async fn serve<F, Fut>(callback: F) -> Result<(), Error>
pub async fn serve<F, Fut>(callback: F) -> Result<!, Error>
where
F: Fn(&str) -> Fut + Clone + Send + 'static,
Fut: Future<Output = Option<Vec<u8>>> + Send + 'static,