Fix wrong go types

This commit is contained in:
2023-07-22 14:28:49 +02:00
parent f36146731b
commit d113f02d90
3 changed files with 5 additions and 3 deletions

View File

@ -0,0 +1,20 @@
package api
import (
"github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/middleware/helmet"
"{{cookiecutter.module_path}}/internal/app/api/v1"
)
func ConfigureRoutes(app *fiber.App) error {
api := app.Group("/api")
api.Use(helmet.New())
err := v1.ConfigureRoutes(api)
if err != nil {
return err
}
return nil
}

View File

@ -0,0 +1,15 @@
package v1
import (
"github.com/gofiber/fiber/v2"
)
func ConfigureRoutes(router fiber.Router) error {
v1 := router.Group("/v1")
v1.Get("/ping", func(c *fiber.Ctx) error {
return c.SendString("pong")
})
return nil
}