fix: move ALTCHA routes to correct location

- Move auth ALTCHA challenge inside auth group
- Move admin ALTCHA challenge to v1 group
- Move test endpoint to v1 group
- This should fix the route registration issue
This commit is contained in:
Patrick Britton 2026-02-16 23:07:18 -06:00
parent 68bfb1d220
commit fcdecacb01

View file

@ -259,6 +259,7 @@ func main() {
auth.GET("/verify", authHandler.VerifyEmail) auth.GET("/verify", authHandler.VerifyEmail)
auth.POST("/forgot-password", authHandler.ForgotPassword) auth.POST("/forgot-password", authHandler.ForgotPassword)
auth.POST("/reset-password", authHandler.ResetPassword) auth.POST("/reset-password", authHandler.ResetPassword)
auth.GET("/altcha-challenge", authHandler.GetAltchaChallenge)
} }
// Test endpoint to verify routing // Test endpoint to verify routing
@ -266,8 +267,7 @@ func main() {
c.JSON(200, gin.H{"message": "Route test successful"}) c.JSON(200, gin.H{"message": "Route test successful"})
}) })
// ALTCHA challenge endpoints (no rate limiting) // Admin ALTCHA challenge endpoint (no auth required)
v1.GET("/auth/altcha-challenge", authHandler.GetAltchaChallenge)
v1.GET("/admin/altcha-challenge", adminHandler.GetAltchaChallenge) v1.GET("/admin/altcha-challenge", adminHandler.GetAltchaChallenge)
authorized := v1.Group("") authorized := v1.Group("")