mirror of
https://github.com/tokio-rs/axum.git
synced 2026-09-06 00:00:17 +02:00
Break Router::nest into nest and nest_service methods
This commit is contained in:
@@ -146,7 +146,7 @@ where
|
||||
T::Future: Send + 'static,
|
||||
{
|
||||
let path = self.show_update_destroy_path();
|
||||
self.router = self.router.nest(&path, svc);
|
||||
self.router = self.router.nest_service(&path, svc);
|
||||
self
|
||||
}
|
||||
|
||||
@@ -159,7 +159,7 @@ where
|
||||
T::Future: Send + 'static,
|
||||
{
|
||||
let path = self.index_create_path();
|
||||
self.router = self.router.nest(&path, svc);
|
||||
self.router = self.router.nest_service(&path, svc);
|
||||
self
|
||||
}
|
||||
|
||||
|
||||
@@ -161,7 +161,7 @@ where
|
||||
.handle_error(spa.handle_error.clone());
|
||||
|
||||
Router::new()
|
||||
.nest(&spa.paths.assets_path, assets_service)
|
||||
.nest_service(&spa.paths.assets_path, assets_service)
|
||||
.fallback(
|
||||
get_service(ServeFile::new(&spa.paths.index_file)).handle_error(spa.handle_error),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user