mirror of
https://github.com/makayabou/asg-server.git
synced 2026-05-02 17:43:36 +02:00
[docs] fix trailing slash problem
This commit is contained in:
parent
bfb2360504
commit
ca50e26e39
@ -48,4 +48,7 @@ tmp/
|
||||
|
||||
# Ignore build and deployments directories
|
||||
deployments/
|
||||
build/
|
||||
build/
|
||||
|
||||
# Example requests files
|
||||
*.http
|
||||
@ -9,6 +9,14 @@ type rootHandler struct {
|
||||
}
|
||||
|
||||
func (h *rootHandler) Register(app *fiber.App) {
|
||||
app.Use(func(c *fiber.Ctx) error {
|
||||
if c.Path() == "/api" {
|
||||
return c.Redirect("/api/", fiber.StatusMovedPermanently)
|
||||
}
|
||||
|
||||
return c.Next()
|
||||
})
|
||||
|
||||
h.healthHandler.Register(app)
|
||||
app.Static("/api", "api")
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user