Skip to content

Commit

Permalink
Don't require S: Debug for impl Debug for Router<S> (#1836)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidpdrsn authored Mar 10, 2023
1 parent dc480f7 commit e56e1b3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 9 deletions.
4 changes: 3 additions & 1 deletion axum/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

# Unreleased

- None.
- **fixed:** Don't require `S: Debug` for `impl Debug for Router<S>` ([#1836])

[#1836]: https://github.com/tokio-rs/axum/pull/1836

# 0.6.10 (03. March, 2023)

Expand Down
10 changes: 2 additions & 8 deletions axum/src/routing/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,7 @@ where
}
}

impl<S, B> fmt::Debug for Router<S, B>
where
S: fmt::Debug,
{
impl<S, B> fmt::Debug for Router<S, B> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.debug_struct("Router")
.field("routes", &self.routes)
Expand Down Expand Up @@ -721,10 +718,7 @@ impl<S, B> Clone for Endpoint<S, B> {
}
}

impl<S, B> fmt::Debug for Endpoint<S, B>
where
S: fmt::Debug,
{
impl<S, B> fmt::Debug for Endpoint<S, B> {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
match self {
Self::MethodRouter(method_router) => {
Expand Down

0 comments on commit e56e1b3

Please sign in to comment.