aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_http.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2012-12-09 12:20:55 +0100
committerKim Alvefur <zash@zash.se>2012-12-09 12:20:55 +0100
commit329ee389c5fdea1e5cab9385accf7fd5fe80c7dc (patch)
tree03956a8a9247babc607ab26b998b387ff6caf3cd /plugins/mod_http.lua
parentfbbd1b1c674b650f3b82997de85a3707d12d7d1d (diff)
downloadprosody-329ee389c5fdea1e5cab9385accf7fd5fe80c7dc.tar.gz
prosody-329ee389c5fdea1e5cab9385accf7fd5fe80c7dc.zip
mod_http: Fix path length pattern
Diffstat (limited to 'plugins/mod_http.lua')
-rw-r--r--plugins/mod_http.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_http.lua b/plugins/mod_http.lua
index e73778ae..018f2ea3 100644
--- a/plugins/mod_http.lua
+++ b/plugins/mod_http.lua
@@ -88,7 +88,7 @@ function module.add_host(module)
local data = handler;
handler = function () return data; end
elseif event_name:sub(-2, -1) == "/*" then
- local base_path_len = #event_name:match("(/.+/)%*$")+1;
+ local base_path_len = #event_name:match("/.+$");
local _handler = handler;
handler = function (event)
local path = event.request.path:sub(base_path_len);