Update Electron

This commit is contained in:
Kenta420 2024-03-15 14:10:24 +07:00
parent cae6d582ac
commit c84ee948f5
22 changed files with 763 additions and 152 deletions

View file

@ -160,7 +160,7 @@ func (ar *AuthRouter) Route(r chi.Router) {
// get userInfo info
userInfo, err := ar.oauth.GetUserInfo(r.Context(), &oauth2.Token{AccessToken: token})
if err != nil {
http.Error(w, "Error getting userInfo info", http.StatusBadRequest)
http.Error(w, "Error getting userInfo info", http.StatusUnauthorized)
return
}

View file

@ -89,7 +89,7 @@ func (o *oauthService) GetUserInfo(ctx context.Context, token *oauth2.Token) (*m
}
if userInfo["error"] != nil {
return nil, errors.New("Error getting user info")
return nil, errors.New("error getting user info")
}
return &models.User{