diff --git a/basics/README.md b/basics/README.md index 361562ec..76b52818 100644 --- a/basics/README.md +++ b/basics/README.md @@ -14,7 +14,7 @@ cargo run - [http://localhost:8080/](http://localhost:8080/static/index.html) - [http://localhost:8080/async/bob](http://localhost:8080/async/bob) -- [http://localhost:8080/user/bob/](http://localhost:8080/user/bob/) plain/text download +- [http://localhost:8080/user/bob/](http://localhost:8080/user/bob/) text/plain download - [http://localhost:8080/test](http://localhost:8080/test) (return status switch GET or POST or other) - [http://localhost:8080/favicon](http://localhost:8080/static/favicon.htmicol) - [http://localhost:8080/welcome](http://localhost:8080/static/welcome.html) diff --git a/basics/src/main.rs b/basics/src/main.rs index c8c73636..7c37e6eb 100644 --- a/basics/src/main.rs +++ b/basics/src/main.rs @@ -82,7 +82,7 @@ fn with_param(req: HttpRequest) -> HttpResponse { println!("{:?}", req); HttpResponse::Ok() - .content_type("test/plain") + .content_type("text/plain") .body(format!("Hello {}!", req.match_info().get("name").unwrap())) }