Send Cache-Control headers by default
This commit is contained in:
parent
aeb1c372bd
commit
21b491c20b
1 changed files with 4 additions and 0 deletions
|
@ -187,6 +187,10 @@ function write(content, src_err)
|
||||||
if not context.headers or not context.headers["content-type"] then
|
if not context.headers or not context.headers["content-type"] then
|
||||||
header("Content-Type", "text/html; charset=utf-8")
|
header("Content-Type", "text/html; charset=utf-8")
|
||||||
end
|
end
|
||||||
|
if not context.headers["cache-control"] then
|
||||||
|
header("Cache-Control", "no-cache")
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
context.eoh = true
|
context.eoh = true
|
||||||
coroutine.yield(3)
|
coroutine.yield(3)
|
||||||
|
|
Loading…
Reference in a new issue