Software /
code /
prosody
Changeset
9996:9bb1bed3e8e3
net.http.files: Bump cache hits so they stay cached
It's not an LRU cache unless this is done.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 04 May 2019 04:48:40 +0200 |
parents | 9995:8d46ecc4bd0c |
children | 9997:7c4631d7b6fb |
files | net/http/files.lua |
diffstat | 1 files changed, 1 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/net/http/files.lua Sat May 04 04:33:41 2019 +0200 +++ b/net/http/files.lua Sat May 04 04:48:40 2019 +0200 @@ -94,6 +94,7 @@ if data and data.etag == etag then response_headers.content_type = data.content_type; data = data.data; + cache:get(orig_path, data); elseif attr.mode == "directory" and path then if full_path:sub(-1) ~= "/" then local dir_path = { is_absolute = true, is_directory = true };