File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -84,7 +84,14 @@ export class UnauthorizedError extends Error {
8484 */
8585export async function auth (
8686 provider : OAuthClientProvider ,
87- { serverUrl, authorizationCode } : { serverUrl : string | URL , authorizationCode ?: string } ) : Promise < AuthResult > {
87+ { serverUrl,
88+ authorizationCode,
89+ scope,
90+ } : {
91+ serverUrl : string | URL ;
92+ authorizationCode ?: string ;
93+ scope ?: string ;
94+ } ) : Promise < AuthResult > {
8895 const metadata = await discoverOAuthMetadata ( serverUrl ) ;
8996
9097 // Handle client registration if needed
@@ -146,7 +153,7 @@ export async function auth(
146153 metadata,
147154 clientInformation,
148155 redirectUrl : provider . redirectUrl ,
149- scope : provider . clientMetadata . scope
156+ scope : scope || provider . clientMetadata . scope ,
150157 } ) ;
151158
152159 await provider . saveCodeVerifier ( codeVerifier ) ;
You can’t perform that action at this time.
0 commit comments