some debugging
This commit is contained in:
@@ -40,7 +40,6 @@ func AuthHandlerRoutes(r fiber.Router) fiber.Router {
|
||||
r.Post("/reset-password", handler.ResetPassword)
|
||||
r.Post("/logout", handler.Logout)
|
||||
r.Post("/refresh", handler.RefreshToken)
|
||||
r.Post("/update-choice", handler.UpdateJWTToken)
|
||||
|
||||
// Google OAuth2
|
||||
r.Get("/google", handler.GoogleLogin)
|
||||
@@ -48,6 +47,7 @@ func AuthHandlerRoutes(r fiber.Router) fiber.Router {
|
||||
|
||||
authProtected := r.Group("", middleware.AuthMiddleware())
|
||||
authProtected.Get("/me", handler.Me)
|
||||
authProtected.Post("/update-choice", handler.UpdateJWTToken)
|
||||
|
||||
return r
|
||||
}
|
||||
@@ -345,9 +345,9 @@ func (h *AuthHandler) CompleteRegistration(c fiber.Ctx) error {
|
||||
return c.Status(fiber.StatusCreated).JSON(response)
|
||||
}
|
||||
|
||||
// CompleteRegistration handles completion of registration with password
|
||||
// Updates JWT Tokens
|
||||
func (h *AuthHandler) UpdateJWTToken(c fiber.Ctx) error {
|
||||
return h.UpdateJWTToken(c)
|
||||
return h.authService.UpdateJWTToken(c)
|
||||
}
|
||||
|
||||
// GoogleLogin redirects the user to Google's OAuth2 consent page
|
||||
|
||||
Reference in New Issue
Block a user