diff --git a/Cargo.toml b/Cargo.toml index 4c942cb..6b3eefc 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "jumpdrive-auth" -version = "2.0.0" +version = "2.1.0" edition = "2021" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/README.md b/README.md index d440963..365728d 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ I currently have no intentions to publish this to crates.io, so for now if you w dependency using: ```toml -jumpdrive-auth = { git = "https://github.com/Jumpdrive-dev/Auth-Services", tag = "2.0.0" } +jumpdrive-auth = { git = "https://github.com/Jumpdrive-dev/Auth-Services", tag = "2.1.0" } ``` ## Features diff --git a/src/models/jwt/jwt_headers.rs b/src/models/jwt/jwt_headers.rs index 858d6ac..2c50adf 100644 --- a/src/models/jwt/jwt_headers.rs +++ b/src/models/jwt/jwt_headers.rs @@ -20,6 +20,15 @@ pub struct JwtHeader { pub cty: Option, } +impl JwtHeader { + pub fn with_cty(value: T) -> JwtHeader { + JwtHeader { + cty: Some(value), + ..JwtHeader::default() + } + } +} + impl Default for JwtHeader { fn default() -> JwtHeader { Self {