Refactor router setup to split routes by auth/protected boundary
This commit is contained in:
13
internal/server/routes_public.go
Normal file
13
internal/server/routes_public.go
Normal file
@@ -0,0 +1,13 @@
|
||||
package server
|
||||
|
||||
import (
|
||||
"github.com/gin-gonic/gin"
|
||||
|
||||
"github.com/dhao2001/mygo/internal/app"
|
||||
"github.com/dhao2001/mygo/internal/handler"
|
||||
)
|
||||
|
||||
func setupPublicRoutes(rg *gin.RouterGroup, webApp *app.WebApp) {
|
||||
versionHandler := handler.NewVersionHandler(webApp.Version)
|
||||
rg.GET("/version", versionHandler.Get)
|
||||
}
|
||||
Reference in New Issue
Block a user