File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed
android/src/main/java/io/fullstack/oauth Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -483,6 +483,7 @@ private WritableMap accessTokenResponse(
483483 if (tokenType == null ) {
484484 tokenType = "Bearer" ;
485485 }
486+
486487 String scope = accessToken .getScope ();
487488 if (scope == null ) {
488489 scope = (String ) cfg .get ("scopes" );
Original file line number Diff line number Diff line change @@ -567,14 +567,21 @@ - (NSDictionary *) getAccountResponse:(DCTAuthAccount *) account
567567 DCTOAuth2Credential *credential = account.credential ;
568568 if (credential != nil ) {
569569
570- NSDictionary *cred = [self dictionaryForCredentialKeys: credential];
570+ NSMutableDictionary *cred = [self dictionaryForCredentialKeys: credential];
571+
572+ DCTOAuth2Account *oauth2Account = (DCTOAuth2Account *) account;
573+ if (oauth2Account.scopes ) {
574+ [cred setObject: oauth2Account.scopes forKey: @" scopes" ];
575+ }
576+
571577 [accountResponse setObject: cred forKey: @" credentials" ];
572578 }
573579 }
574580 [accountResponse setValue: [account identifier ] forKey: @" identifier" ];
575581 if (account.userInfo != nil ) {
576582 [accountResponse setObject: [account userInfo ] forKey: @" user_info" ];
577583 }
584+
578585 return accountResponse;
579586}
580587
You can’t perform that action at this time.
0 commit comments