summaryrefslogtreecommitdiff
path: root/middleware.go
diff options
context:
space:
mode:
authorJeff Carr <[email protected]>2025-09-07 19:14:20 -0500
committerJeff Carr <[email protected]>2025-09-07 21:41:18 -0500
commitc2e0e8e80b5831996da38efbfaa4bb206875bf40 (patch)
tree2e7fd585eaefbeddb6421e96e1b0b043deb4b72e /middleware.go
parenteae2c3be2bcd6c30fc665ab1a99edb26110115d2 (diff)
start using a standard http PB
Diffstat (limited to 'middleware.go')
-rw-r--r--middleware.go10
1 files changed, 2 insertions, 8 deletions
diff --git a/middleware.go b/middleware.go
index 803e162..10048cd 100644
--- a/middleware.go
+++ b/middleware.go
@@ -1,13 +1,8 @@
package main
-import (
- "bytes"
- "context"
- "io/ioutil"
- "log"
- "net/http"
-)
+// a middleware example. probably not interesting since we only pass protobufs
+/*
// Define a key type to avoid context key collisions.
type contextKey string
@@ -42,7 +37,6 @@ func bufferBodyMiddleware(next http.Handler) http.Handler {
})
}
-/*
// okHandler is the final handler. It can now safely access the body from the context,
// knowing that other middleware might have also read it.
func okHandler(w http.ResponseWriter, r *http.Request) {