From b548c773d1cdbfa56ab0443d722bf0ea3a6b51aa Mon Sep 17 00:00:00 2001 From: cduvray Date: Fri, 23 Aug 2024 08:05:59 +0200 Subject: [PATCH] fix(doc): use automatic links, add module comment --- demo-server/src/main.rs | 2 ++ jwt-authorizer/src/claims.rs | 4 ++-- jwt-authorizer/src/error.rs | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/demo-server/src/main.rs b/demo-server/src/main.rs index 6446347..be7f7e2 100644 --- a/demo-server/src/main.rs +++ b/demo-server/src/main.rs @@ -1,3 +1,5 @@ +//! Demo server - for demo and testing purposes + use axum::{routing::get, Router}; use jwt_authorizer::{ error::InitError, AuthError, Authorizer, IntoLayer, JwtAuthorizer, JwtClaims, Refresh, RefreshStrategy, diff --git a/jwt-authorizer/src/claims.rs b/jwt-authorizer/src/claims.rs index 894af54..760b605 100644 --- a/jwt-authorizer/src/claims.rs +++ b/jwt-authorizer/src/claims.rs @@ -1,7 +1,7 @@ use serde::{Deserialize, Serialize}; /// The number of seconds from 1970-01-01T00:00:00Z UTC until the specified UTC date/time ignoring leap seconds. -/// (https://www.rfc-editor.org/rfc/rfc7519#section-2) +/// () #[derive(Deserialize, Serialize, Clone, PartialEq, Eq, Debug)] pub struct NumericDate(pub i64); @@ -53,7 +53,7 @@ pub struct StringList(Vec); /// Claims mentioned in the JWT specifications. /// -/// https://www.rfc-editor.org/rfc/rfc7519#section-4.1 +/// #[derive(Deserialize, Serialize, Clone, Debug)] pub struct RegisteredClaims { #[serde(skip_serializing_if = "Option::is_none")] diff --git a/jwt-authorizer/src/error.rs b/jwt-authorizer/src/error.rs index 56f0a92..465eb31 100644 --- a/jwt-authorizer/src/error.rs +++ b/jwt-authorizer/src/error.rs @@ -139,7 +139,7 @@ impl From for Response { } } -/// (https://datatracker.ietf.org/doc/html/rfc6750#section-3.1) +/// () impl IntoResponse for AuthError { fn into_response(self) -> Response { match self {