mirror of
https://github.com/better-auth/better-auth.git
synced 2026-08-01 10:50:40 -05:00
fix(oauth): extended oauth2 tokens with refresh_token_expires_in field (#3167)
* docs: corrected github user email scope name * docs: cubic dev suggestion * feat(oauht2/utils): added `refresh_token_expires_in` field in `getOAuth2Tokens`
This commit is contained in:
@@ -18,6 +18,9 @@ export function getOAuth2Tokens(data: Record<string, any>): OAuth2Tokens {
|
||||
accessTokenExpiresAt: data.expires_in
|
||||
? getDate(data.expires_in, "sec")
|
||||
: undefined,
|
||||
refreshTokenExpiresAt: data.refresh_token_expires_in
|
||||
? getDate(data.refresh_token_expires_in, "sec")
|
||||
: undefined,
|
||||
scopes: data?.scope
|
||||
? typeof data.scope === "string"
|
||||
? data.scope.split(" ")
|
||||
|
||||
Reference in New Issue
Block a user