Fix sentry initialization
@@ -74,7 +74,7 @@ func (rr *responseRecorder) send(w http.ResponseWriter) {
func ErrorLoggingMiddleware(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
hub := sentry.CurrentHub().Clone()
- hub.Scope().SetRequest(sentry.Request{}.FromHTTPRequest(r))
+ hub.Scope().SetRequest(r)
ctx := sentry.SetHubOnContext(r.Context(), hub)
// Record response from next handler, recovering any panics therein
