summaryrefslogtreecommitdiff
path: root/system/db/cache.go
diff options
context:
space:
mode:
Diffstat (limited to 'system/db/cache.go')
-rw-r--r--system/db/cache.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/db/cache.go b/system/db/cache.go
index 4076848..e964906 100644
--- a/system/db/cache.go
+++ b/system/db/cache.go
@@ -18,7 +18,7 @@ func CacheControl(next http.Handler) http.HandlerFunc {
res.Header().Add("Etag", etag)
res.Header().Add("Cache-Control", policy)
- if match := res.Header().Get("If-None-Match"); match != "" {
+ if match := req.Header.Get("If-None-Match"); match != "" {
if strings.Contains(match, etag) {
fmt.Println("matched etag")
res.WriteHeader(http.StatusNotModified)