Browse Source

Disable cache for action responses

Vova Tkach 6 years ago
parent
commit
69d9fddab6
1 changed files with 1 additions and 0 deletions
  1. 1 0
      engine/actions/actions.go

+ 1 - 0
engine/actions/actions.go

@@ -37,6 +37,7 @@ func (e *Action) Call() bool {
 		if action != "" {
 			fn, ok := e.list[action]
 			if ok {
+				(*e.W).Header().Set("Cache-Control", "no-cache, no-store, must-revalidate")
 				(*e.W).Header().Set("Content-Type", "text/html; charset=utf-8")
 				fn(e)
 				return true