File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -53,16 +53,16 @@ tokio = { version = "1.26.0", features = ["full"] }
5353``` rust
5454// src/main.rs
5555
56- // ...
56+ use windmark :: response :: Response ;
5757
5858#[windmark:: main]
5959async fn main () -> Result <(), Box <dyn std :: error :: Error >> {
6060 windmark :: router :: Router :: new ()
6161 . set_private_key_file (" windmark_private.pem" )
6262 . set_certificate_file (" windmark_public.pem" )
63- . mount (" /" , windmark :: success! (" Hello, World!" ))
63+ . mount (" /" , | _ | Response :: success (" Hello, World!" ))
6464 . set_error_handler (| _ |
65- windmark :: response :: Response :: permanent_failure (" This route does not exist!" )
65+ Response :: permanent_failure (" This route does not exist!" )
6666 )
6767 . run ()
6868 . await
@@ -74,14 +74,14 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
7474``` rust
7575// src/main.rs
7676
77- // ...
77+ use windmark :: response :: Response ;
7878
7979#[rossweisse:: router]
8080struct Router ;
8181
8282#[rossweisse:: router]
8383impl Router {
84- #[route(index)]
84+ #[rossweisse :: route(index)]
8585 pub fn index (
8686 _context : windmark :: context :: RouteContext ,
8787 ) -> Response {
You can’t perform that action at this time.
0 commit comments