mirror of
https://github.com/cf-sonr/motr.git
synced 2026-01-12 02:59:13 +00:00
feat: add KV store middleware for session and handle management
This commit is contained in:
@@ -10,6 +10,7 @@ import (
|
||||
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/sonr-io/motr/middleware/database"
|
||||
"github.com/sonr-io/motr/middleware/kvstore"
|
||||
"github.com/sonr-io/motr/middleware/marketapi"
|
||||
"github.com/sonr-io/motr/middleware/session"
|
||||
"github.com/sonr-io/motr/routes"
|
||||
@@ -26,7 +27,7 @@ import (
|
||||
// Setup the HTTP handler
|
||||
func loadHandler() http.Handler {
|
||||
e := echo.New()
|
||||
e.Use(session.Middleware(), database.Middleware(), marketapi.Middleware())
|
||||
e.Use(session.Middleware(), database.Middleware(), kvstore.Middleware(), marketapi.Middleware())
|
||||
routes.SetupViews(e)
|
||||
routes.SetupPartials(e)
|
||||
return e
|
||||
|
||||
@@ -10,6 +10,7 @@ import (
|
||||
|
||||
"github.com/labstack/echo/v4"
|
||||
"github.com/sonr-io/motr/middleware/database"
|
||||
"github.com/sonr-io/motr/middleware/kvstore"
|
||||
"github.com/sonr-io/motr/middleware/session"
|
||||
"github.com/sonr-io/motr/middleware/sonrapi"
|
||||
"github.com/sonr-io/motr/middleware/webauthn"
|
||||
@@ -27,7 +28,7 @@ import (
|
||||
// Setup the HTTP handler
|
||||
func loadHandler() http.Handler {
|
||||
e := echo.New()
|
||||
e.Use(session.Middleware(), database.Middleware(), sonrapi.Middleware(), webauthn.Middleware())
|
||||
e.Use(session.Middleware(), database.Middleware(), kvstore.Middleware(), sonrapi.Middleware(), webauthn.Middleware())
|
||||
routes.SetupViews(e)
|
||||
routes.SetupPartials(e)
|
||||
return e
|
||||
|
||||
Reference in New Issue
Block a user