From aa28aca930a94bbac65e304a5ce167b62f8edfed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 25 Jan 2025 17:30:45 +0000 Subject: [PATCH 1/2] chore(deps): bump the all-dependencies group with 2 updates Updates the requirements on [axum](https://github.com/tokio-rs/axum) and [axum-extra](https://github.com/tokio-rs/axum) to permit the latest version. Updates `axum` to 0.8.1 - [Release notes](https://github.com/tokio-rs/axum/releases) - [Changelog](https://github.com/tokio-rs/axum/blob/main/CHANGELOG.md) - [Commits](https://github.com/tokio-rs/axum/commits) Updates `axum-extra` to 0.10.0 - [Release notes](https://github.com/tokio-rs/axum/releases) - [Changelog](https://github.com/tokio-rs/axum/blob/main/CHANGELOG.md) - [Commits](https://github.com/tokio-rs/axum/compare/axum-extra-v0.9.6...axum-extra-v0.10.0) --- updated-dependencies: - dependency-name: axum dependency-type: direct:production dependency-group: all-dependencies - dependency-name: axum-extra dependency-type: direct:production dependency-group: all-dependencies ... Signed-off-by: dependabot[bot] --- Cargo.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index d1114d5..dc21836 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,8 +8,8 @@ license = "MIT" repository = "https://github.com/cmackenzie1/axum-jwt-auth" [dependencies] -axum = { version = "0.7", features = ["macros"] } -axum-extra = { version = "0.9.6", features = ["typed-header"] } +axum = { version = "0.8", features = ["macros"] } +axum-extra = { version = "0.10.0", features = ["typed-header"] } jsonwebtoken = { version = "9" } reqwest = { version = "0.12", default-features = false, features = [ "json", From 17da32f5da19435e678f2d88fe2798e4f5494aca Mon Sep 17 00:00:00 2001 From: Cole MacKenzie Date: Sat, 25 Jan 2025 09:35:37 -0800 Subject: [PATCH 2/2] Remove axum::async_trait --- src/axum.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/axum.rs b/src/axum.rs index 78b11da..ca1de29 100644 --- a/src/axum.rs +++ b/src/axum.rs @@ -2,7 +2,7 @@ use axum::extract::FromRef; use axum::http::StatusCode; use axum::response::Response; use axum::RequestPartsExt; -use axum::{async_trait, http::request::Parts, response::IntoResponse}; +use axum::{http::request::Parts, response::IntoResponse}; use axum_extra::headers::authorization::Bearer; use axum_extra::headers::Authorization; use axum_extra::TypedHeader; @@ -43,7 +43,6 @@ pub struct JwtDecoderState { pub decoder: Decoder, } -#[async_trait] impl axum::extract::FromRequestParts for Claims where JwtDecoderState: FromRef,