projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e3a8cf5
)
mod_http_files: Preserve a trailing / in paths (fixes #639)
author
Kim Alvefur
<zash@zash.se>
Thu, 3 Mar 2016 14:31:46 +0000
(15:31 +0100)
committer
Kim Alvefur
<zash@zash.se>
Thu, 3 Mar 2016 14:31:46 +0000
(15:31 +0100)
plugins/mod_http_files.lua
patch
|
blob
|
history
diff --git
a/plugins/mod_http_files.lua
b/plugins/mod_http_files.lua
index fc39628ccba073f97ff6ea615811609708c6e980..53b6469bb0e2f7b3a4c01a0d4c8003aed3fbd9a3 100644
(file)
--- 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