]> granicus.if.org Git - ejabberd/commitdiff
* src/web/ejabberd_http.erl: Add 'http_bind' option for easy
authorBadlop <badlop@process-one.net>
Sat, 22 Dec 2007 14:23:37 +0000 (14:23 +0000)
committerBadlop <badlop@process-one.net>
Sat, 22 Dec 2007 14:23:37 +0000 (14:23 +0000)
configuration of HTTP-Binding

SVN Revision: 1101

ChangeLog
src/web/ejabberd_http.erl

index 56279b99bbf61aec8f386e3b3d2dc2b5ca842b61..b5f35e8358d38138cfb9c09b74626ac3facc7752 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2007-12-22  Badlop  <badlop@process-one.net>
 
+       * src/web/ejabberd_http.erl: Add 'http_bind' option for easy
+       configuration of HTTP-Binding
+
        * src/mod_announce.erl: Fixed unnoticeable bug related to Node
        matching. Renamed some nonstandard node names according to
        XEP-0133. Small reordering of clauses. When editing MOTD, display
index 90d871d225e68582ffaffb9c171ef2ab41c056ea..db6ac620fc886555a6ffba22cbc302f74d345eb2 100644 (file)
@@ -78,19 +78,24 @@ start_link({SockMod, Socket}, Opts) ->
            ok
     end,
 
-    %% XXX bard: for backward compatibility: expand web_admin and
-    %% http_poll in Opts respectively to {["admin"],
-    %% ejabberd_web_admin} and {["http-poll"], ejabberd_http_poll}
+    %% XXX bard: for backward compatibility, expand in Opts:
+    %%  web_admin -> {["admin"], ejabberd_web_admin} 
+    %%  http_bind -> {["http-bind"], mod_http_bind}
+    %%  http_poll -> {["http-poll"], ejabberd_http_poll}
 
     RequestHandlers =
        case lists:keysearch(request_handlers, 1, Opts) of
-             {value, {request_handlers, H}} -> H;
-             false -> []
+           {value, {request_handlers, H}} -> H;
+           false -> []
         end ++
         case lists:member(web_admin, Opts) of
             true -> [{["admin"], ejabberd_web_admin}];
             false -> []
         end ++
+        case lists:member(http_bind, Opts) of
+            true -> [{["http-bind"], mod_http_bind}];
+            false -> []
+        end ++
         case lists:member(http_poll, Opts) of
             true -> [{["http-poll"], ejabberd_http_poll}];
             false -> []