feat: add recover middleware
All checks were successful
/ build-and-push-image (push) Successful in 1m15s

This commit is contained in:
log101 2024-09-03 11:26:12 +03:00
parent 70d446b067
commit 238b542aeb

View File

@ -9,6 +9,7 @@ import (
"github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/middleware/cors"
"github.com/gofiber/fiber/v2/middleware/logger"
"github.com/gofiber/fiber/v2/middleware/recover"
"github.com/joho/godotenv"
)
@ -29,6 +30,7 @@ func main() {
DB.InitDB()
app := fiber.New()
app.Use(recover.New())
app.Use(logger.New())
app.Use(cors.New(cors.Config{
AllowOrigins: "http://localhost:4321",