Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/utils/token/getClaim.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import { getClaims } from "./getClaims";
*
* @param keyName key to get from the token
* @param {("accessToken"|"idToken")} [tokenType="accessToken"] - Type of token to get claims from
* @returns { Promise<string | number | string[] | null> }
* @returns { Promise<string | number | string[] | { id: string; name: string }[] | null> }
*/
export const getClaim = async <T = JWTDecoded, V = string | number | string[]>(
export const getClaim = async <T = JWTDecoded, V = string | number | string[] | { id: string; name: string }[]>(
keyName: keyof T,
tokenType: "accessToken" | "idToken" = "accessToken",
): Promise<{
Expand Down
Loading