♻️ Basiclly moved to Dealer from Consul

This commit is contained in:
2024-07-15 00:01:17 +08:00
parent a60be78ce6
commit 69fb9531cb
40 changed files with 298 additions and 1451 deletions

View File

@ -1,8 +1,6 @@
package api
import (
"git.solsynth.dev/hydrogen/passport/pkg/internal/server/exts"
"github.com/gofiber/contrib/websocket"
"github.com/gofiber/fiber/v2"
)
@ -99,13 +97,6 @@ func MapAPIs(app *fiber.App) {
developers.Post("/notify", notifyUser)
}
api.Use(func(c *fiber.Ctx) error {
if err := exts.EnsureAuthenticated(c); err != nil {
return err
}
return c.Next()
}).Get("/ws", websocket.New(listenWebsocket))
api.All("/*", func(c *fiber.Ctx) error {
return fiber.ErrNotFound
})