diff --git a/routers/web/auth/oauth.go b/routers/web/auth/oauth.go index 4d8fbcb7a5..62b7b0b6d3 100644 --- a/routers/web/auth/oauth.go +++ b/routers/web/auth/oauth.go @@ -1188,7 +1188,7 @@ func getSSHKeys(source *oauth2.Source, gothUser *goth.User) ([]string, error) { key := source.AttributeSSHPublicKey value, exists := gothUser.RawData[key] if !exists { - return nil, fmt.Errorf("attribute '%s' not found in user data", key) + return []string{}, nil } rawSlice, ok := value.([]any)