From 071aa123e8332e8955d3c2ce3b5a82dd9080df13 Mon Sep 17 00:00:00 2001 From: Badlop Date: Wed, 10 Feb 2010 18:42:42 +0100 Subject: [PATCH] Allow a request_handler to serve a file in root of HTTP --- src/web/ejabberd_http.erl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/web/ejabberd_http.erl b/src/web/ejabberd_http.erl index 47b206395..821fffb91 100644 --- a/src/web/ejabberd_http.erl +++ b/src/web/ejabberd_http.erl @@ -317,7 +317,8 @@ process([], _) -> process(Handlers, Request) -> [{HandlerPathPrefix, HandlerModule} | HandlersLeft] = Handlers, - case lists:prefix(HandlerPathPrefix, Request#request.path) of + case (lists:prefix(HandlerPathPrefix, Request#request.path) or + (HandlerPathPrefix==Request#request.path)) of true -> ?DEBUG("~p matches ~p", [Request#request.path, HandlerPathPrefix]), %% LocalPath is the path "local to the handler", i.e. if