Skip to content

refactor: adopt jwt.MapClaims to replace custom MapClaims type#342

Merged
appleboy merged 1 commit intomasterfrom
patch11
Feb 24, 2025
Merged

refactor: adopt jwt.MapClaims to replace custom MapClaims type#342
appleboy merged 1 commit intomasterfrom
patch11

Conversation

@appleboy
Copy link
Owner

  • Remove the custom MapClaims type definition
  • Replace MapClaims with jwt.MapClaims in PayloadFunc, GetClaimsFromJWT, ExtractClaims, and ExtractClaimsFromToken functions
  • Update test cases to use jwt.MapClaims instead of the custom MapClaims
  • Update ConvertClaims function to accept jwt.MapClaims

fix #341

… codebase

- Remove the custom `MapClaims` type definition
- Replace `MapClaims` with `jwt.MapClaims` in `PayloadFunc`, `GetClaimsFromJWT`, `ExtractClaims`, and `ExtractClaimsFromToken` functions
- Update test cases to use `jwt.MapClaims` instead of the custom `MapClaims`
- Update `ConvertClaims` function to accept `jwt.MapClaims`

Signed-off-by: appleboy <appleboy.tw@gmail.com>
@appleboy appleboy merged commit 74e77e5 into master Feb 24, 2025
6 checks passed
@appleboy appleboy deleted the patch11 branch February 24, 2025 12:45
@fabszabo
Copy link

fabszabo commented Mar 14, 2025

This is not a refactor. This is a breaking change

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Replace IdentityHandler's parameter jwt.MapClaims with MapClaims

2 participants