From ec30ed1f0b2120a70331351a1f1afeac57285e71 Mon Sep 17 00:00:00 2001 From: Runxi Yu Date: Mon, 18 Aug 2025 04:18:50 +0800 Subject: Make logging in work --- forged/internal/incoming/web/router.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'forged/internal/incoming/web/router.go') diff --git a/forged/internal/incoming/web/router.go b/forged/internal/incoming/web/router.go index c1a0bc0..07e19a5 100644 --- a/forged/internal/incoming/web/router.go +++ b/forged/internal/incoming/web/router.go @@ -152,6 +152,8 @@ func (r *Router) ServeHTTP(w http.ResponseWriter, req *http.Request) { Queries: r.queries, } + req = req.WithContext(wtypes.WithBaseData(req.Context(), bd)) + bd.RefType, bd.RefName, err = GetParamRefTypeName(req) if err != nil { r.err400(w, bd, "Error parsing ref query parameters: "+err.Error()) @@ -202,7 +204,7 @@ func (r *Router) ServeHTTP(w http.ResponseWriter, req *http.Request) { } // Attach BaseData to request context. - req = req.WithContext(wtypes.WithBaseData(req.Context(), bd)) + // req = req.WithContext(wtypes.WithBaseData(req.Context(), bd)) // Enforce method now. if rt.method != "" && -- cgit v1.2.3