Make web::Path innards public

So we can do something like this:
```
async fn delete_channel_message(
    web::Path((channel_id, message_id)): web::Path<(Snowflake, Snowflake)>,
) {
  // here channel_id and message_id are Snowflakes,
  // and not web::Path<Snowflake>
}
```

Dunno why other web types are public and this is not.
This commit is contained in:
Iria.Somobu 2025-02-27 16:27:21 +03:00
parent e0918fb179
commit 8a3a1f2eec
2 changed files with 3 additions and 1 deletions

View File

@ -2,6 +2,8 @@
## Unreleased
- Make contents of `web::Path` public.
## 4.9.0
### Added

View File

@ -54,7 +54,7 @@ use crate::{
/// }
/// ```
#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Deref, DerefMut, AsRef, Display, From)]
pub struct Path<T>(T);
pub struct Path<T>(pub T);
impl<T> Path<T> {
/// Unwrap into inner `T` value.