@@ -80,12 +80,12 @@ func (err errCallback) Error() string {
8080}
8181
8282type userInfoResponse struct {
83- Sub string `json:"sub"`
84- Name string `json:"name"`
85- Username string `json:"preferred_username"`
86- Email string `json:"email"`
87- Picture string `json:"picture"`
88- Groups []string `json:"groups"`
83+ Sub string `json:"sub"`
84+ Name string `json:"name"`
85+ PreferredUsername string `json:"preferred_username"`
86+ Email string `json:"email"`
87+ Picture string `json:"picture"`
88+ Groups []string `json:"groups"`
8989}
9090
9191// InfoOAuth manages request for userinfo endpoint
@@ -97,11 +97,11 @@ func InfoOAuth(ctx *context.Context) {
9797 }
9898
9999 response := & userInfoResponse {
100- Sub : fmt .Sprint (ctx .Doer .ID ),
101- Name : ctx .Doer .FullName ,
102- Username : ctx .Doer .Name ,
103- Email : ctx .Doer .Email ,
104- Picture : ctx .Doer .AvatarLink (ctx ),
100+ Sub : fmt .Sprint (ctx .Doer .ID ),
101+ Name : ctx .Doer .FullName ,
102+ PreferredUsername : ctx .Doer .Name ,
103+ Email : ctx .Doer .Email ,
104+ Picture : ctx .Doer .AvatarLink (ctx ),
105105 }
106106
107107 groups , err := oauth2_provider .GetOAuthGroupsForUser (ctx , ctx .Doer )
0 commit comments