diff --git a/src/bin/main.rs b/src/bin/main.rs index 3132d52..f2e355b 100644 --- a/src/bin/main.rs +++ b/src/bin/main.rs @@ -71,5 +71,5 @@ async fn main(spawner: Spawner) -> ! { #[embassy_executor::task] async fn http_api_serve_task(mut service: HttpApiService<'static, HttpApiProps>) { - service.serve().await; + service.run().await; } diff --git a/src/http_api.rs b/src/http_api.rs index 1a410c6..5aca8c5 100644 --- a/src/http_api.rs +++ b/src/http_api.rs @@ -28,7 +28,7 @@ impl Default for HttpApiConfig { } pub struct HttpApiService<'a, AB: AppBuilder> { - pub config: HttpApiConfig, + config: HttpApiConfig, net_stack: Stack<'a>, app: AppRouter, @@ -52,7 +52,7 @@ impl<'a, AB: AppBuilder> HttpApiService<'a, AB> { } } - pub async fn serve(&mut self) { + pub async fn run(&mut self) { picoserve::Server::new( &self.app, &self.config.web_serve_config,