diff options
author | Matthew Wild <mwild1@gmail.com> | 2012-11-29 07:16:45 +0500 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2012-11-29 07:16:45 +0500 |
commit | 36dd5eea337aebc8eb35b70e3fa3a93fc48f7a4b (patch) | |
tree | 946f436f1268fd970de15a3d8ef7d11a38fff245 /plugins | |
parent | fa1aed4db29880ce158b889852899fa45c7dd88b (diff) | |
parent | 3e74495e5557a7d73385b3894a32e60be0356a46 (diff) | |
download | prosody-36dd5eea337aebc8eb35b70e3fa3a93fc48f7a4b.tar.gz prosody-36dd5eea337aebc8eb35b70e3fa3a93fc48f7a4b.zip |
Merge 0.9->trunk
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mod_admin_adhoc.lua | 9 | ||||
-rw-r--r-- | plugins/mod_http.lua | 4 |
2 files changed, 2 insertions, 11 deletions
diff --git a/plugins/mod_admin_adhoc.lua b/plugins/mod_admin_adhoc.lua index aa1af3ff..9f3175d0 100644 --- a/plugins/mod_admin_adhoc.lua +++ b/plugins/mod_admin_adhoc.lua @@ -212,15 +212,6 @@ function end_user_session_handler(self, data, state) end end -local end_user_session_layout = dataforms_new{ - title = "Ending a User Session"; - instructions = "Fill out this form to end a user's session."; - - { name = "FORM_TYPE", type = "hidden", value = "http://jabber.org/protocol/admin" }; - { name = "accountjids", type = "jid-multi", label = "The Jabber ID(s) for which to end sessions" }; -}; - - function get_user_password_handler(self, data, state) local get_user_password_layout = dataforms_new{ title = "Getting User's Password"; diff --git a/plugins/mod_http.lua b/plugins/mod_http.lua index f386f870..e73778ae 100644 --- a/plugins/mod_http.lua +++ b/plugins/mod_http.lua @@ -88,10 +88,10 @@ function module.add_host(module) local data = handler; handler = function () return data; end elseif event_name:sub(-2, -1) == "/*" then - local base_path = event_name:match("/(.+)/*$"); + local base_path_len = #event_name:match("(/.+/)%*$")+1; local _handler = handler; handler = function (event) - local path = event.request.path:sub(#base_path+1); + local path = event.request.path:sub(base_path_len); return _handler(event, path); end; end |