Skip to content

Commit

Permalink
allow OPTIONS caching
Browse files Browse the repository at this point in the history
  • Loading branch information
joshblakeley committed Aug 2, 2018
1 parent 10e7ce8 commit 5d3aa04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mw_redis_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func (m *RedisCacheMiddleware) decodePayload(payload string) (string, string, er
func (m *RedisCacheMiddleware) ProcessRequest(w http.ResponseWriter, r *http.Request, _ interface{}) (error, int) {

// Only allow idempotent (safe) methods
if r.Method != "GET" && r.Method != "HEAD" {
if r.Method != "GET" && r.Method != "HEAD" && r.Method != "OPTIONS" {
return nil, http.StatusOK
}

Expand Down

0 comments on commit 5d3aa04

Please sign in to comment.