Skip to content

Commit 1e903d0

Browse files
authored
docs(volo-http): update volo-http json extractor related contents to … (#1539)
1 parent a175d48 commit 1e903d0

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

content/en/docs/volo/volo-http/tutorials/response.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ In the framework, types such as `Form`, `Json`, etc. also implement `IntoRespons
4545

4646
```rust
4747
use volo_http::{
48-
json::Json,
4948
server::{
49+
extract::Json,
5050
route::{get, post, Router},
5151
IntoResponse,
5252
},

content/en/docs/volo/volo-http/tutorials/route.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -376,10 +376,10 @@ use std::convert::Infallible;
376376

377377
use volo_http::{
378378
context::ServerContext,
379-
json::Json,
380379
request::ServerRequest,
381380
response::ServerResponse,
382381
server::{
382+
extract::Json,
383383
route::{post_service, Router},
384384
IntoResponse,
385385
},
@@ -410,4 +410,4 @@ pub fn json_test_router() -> Router {
410410
}
411411
```
412412

413-
The final run is expected to be consistent with `json_get` and `json_post`.
413+
The final run is expected to be consistent with `json_get` and `json_post`.

content/zh/docs/volo/volo-http/tutorials/response.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ async fn teapot() -> StatusCode { StatusCode::IM_A_TEAPOT }
4646

4747
```rust
4848
use volo_http::{
49-
json::Json,
5049
server::{
50+
extract::Json,
5151
route::{get, post, Router},
5252
IntoResponse,
5353
},

content/zh/docs/volo/volo-http/tutorials/route.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -372,10 +372,10 @@ use std::convert::Infallible;
372372

373373
use volo_http::{
374374
context::ServerContext,
375-
json::Json,
376375
request::ServerRequest,
377376
response::ServerResponse,
378377
server::{
378+
extract::Json,
379379
route::{post_service, Router},
380380
IntoResponse,
381381
},
@@ -406,4 +406,4 @@ pub fn json_test_router() -> Router {
406406
}
407407
```
408408

409-
最终运行的效果预期与 `json_get``json_post` 一致
409+
最终运行的效果预期与 `json_get``json_post` 一致

0 commit comments

Comments
 (0)