mirror of
https://github.com/tokio-rs/axum.git
synced 2025-01-16 14:33:02 +01:00
Document breaking changes related to nest
(#1684)
This commit is contained in:
parent
1aa357c879
commit
be9a8c0380
1 changed files with 5 additions and 0 deletions
|
@ -158,6 +158,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
async fn fallback() {}
|
||||
```
|
||||
|
||||
- **breaking:** It is no longer supported to `nest` twice at the same path, i.e.
|
||||
`.nest("/foo", a).nest("/foo", b)` will panic. Instead use `.nest("/foo", a.merge(b))`
|
||||
- **breaking:** It is no longer supported to `nest` a router and add a route at
|
||||
the same path, such as `.nest("/a", _).route("/a", _)`. Instead use
|
||||
`.nest("/a/", _).route("/a", _)`.
|
||||
- **changed:** `Router::nest` now only accepts `Router`s, the general-purpose
|
||||
`Service` nesting method has been renamed to `nest_service` ([#1368])
|
||||
- **breaking:** Allow `Error: Into<Infallible>` for `Route::{layer, route_layer}` ([#924])
|
||||
|
|
Loading…
Reference in a new issue