From 31c0a34728dfc3f72cb7fe2072929c339f3625cf Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Thu, 3 Mar 2016 15:31:46 +0100 Subject: mod_http_files: Preserve a trailing / in paths (fixes #639) --- plugins/mod_http_files.lua | 3 +++ 1 file changed, 3 insertions(+) (limited to 'plugins/mod_http_files.lua') diff --git a/plugins/mod_http_files.lua b/plugins/mod_http_files.lua index fc39628c..53b6469b 100644 --- a/plugins/mod_http_files.lua +++ b/plugins/mod_http_files.lua @@ -75,6 +75,9 @@ function sanitize_path(path) out[c] = component; end end + if path:sub(-1,-1) == "/" then + out[c+1] = ""; + end return "/"..table.concat(out, "/"); end -- cgit v1.2.3