diff --git a/http.go b/http.go index 41f9705..88117d9 100644 --- a/http.go +++ b/http.go @@ -60,7 +60,7 @@ func CreateServer(config *toml.Tree) *Server { router: gin.New(), authhf: &auth.AnonAccountHandler{}, } - server.router.Use(func(c *gin.Context) { + server.Use(func(c *gin.Context) { c.Set("account", server.authhf.Account(c)) }) if err := config.Unmarshal(server.conf); err != nil {