File tree Expand file tree Collapse file tree 3 files changed +4
-16
lines changed Expand file tree Collapse file tree 3 files changed +4
-16
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,3 @@ func (a *AccessRequest) GetRefreshTokenGrantedScopes() (scopes Arguments) {
5050func (a * AccessRequest ) SetRefreshTokenGrantedScopes (scopes Arguments ) {
5151 a .RefreshTokenGrantedScope = scopes
5252}
53-
54- func (a * AccessRequest ) SetGrantedScopes (scopes Arguments ) {
55- a .GrantedScope = scopes
56- }
Original file line number Diff line number Diff line change @@ -186,15 +186,11 @@ func (c *RefreshTokenGrantHandler) PopulateTokenEndpointResponse(ctx context.Con
186186 }
187187
188188 if rtRequest , ok := requester .(fosite.RefreshTokenAccessRequester ); ok {
189- r := requester .Sanitize ([]string {}).(* fosite.Request )
190- r .SetID (ts .GetID ())
189+ rtStoreReq := requester .Sanitize ([]string {}).(* fosite.Request )
190+ rtStoreReq .SetID (ts .GetID ())
191191
192- rtStoreReq := & fosite.AccessRequest {
193- Request : * r ,
194- }
195-
196- rtStoreReq .SetRequestedScopes (rtRequest .GetRefreshTokenRequestedScopes ())
197- rtStoreReq .SetGrantedScopes (rtRequest .GetRefreshTokenGrantedScopes ())
192+ rtStoreReq .RequestedScope = rtRequest .GetRefreshTokenRequestedScopes ()
193+ rtStoreReq .GrantedScope = rtRequest .GetRefreshTokenGrantedScopes ()
198194
199195 if err = c .TokenRevocationStorage .CreateRefreshTokenSession (ctx , refreshSignature , rtStoreReq ); err != nil {
200196 return err
Original file line number Diff line number Diff line change @@ -260,10 +260,6 @@ type RefreshTokenAccessRequester interface {
260260 // SetRefreshTokenGrantedScopes sets all granted scopes specifically for the refresh token.
261261 SetRefreshTokenGrantedScopes (scopes Arguments )
262262
263- // SetGrantedScopes sets all granted scopes. This is specifically used in the refresh flow to restore the originally
264- // granted scopes to the session.
265- SetGrantedScopes (scopes Arguments )
266-
267263 AccessRequester
268264}
269265
You can’t perform that action at this time.
0 commit comments