diff --git a/content/docs/server.md b/content/docs/server.md index b8c03a0..e5bc1c2 100644 --- a/content/docs/server.md +++ b/content/docs/server.md @@ -43,7 +43,7 @@ For this reason, any long, non-cpu-bound operation (e.g. I/O, database operation ```rust async fn my_handler() -> impl Responder { - tokio::time::delay_for(Duration::from_secs(5)).await; // <-- Ok. Worker thread will handle other requests here + tokio::time::sleep(Duration::from_secs(5)).await; // <-- Ok. Worker thread will handle other requests here "response" } ```