plugins/mod_bosh.lua
changeset 11775 4c0802b52673
parent 11737 27699cc148df
child 11812 c24580a214f3
--- a/plugins/mod_bosh.lua	Mon Sep 06 23:21:25 2021 +0200
+++ b/plugins/mod_bosh.lua	Mon Jun 21 22:50:23 2021 +0200
@@ -543,13 +543,17 @@
 	}) or "This is the Prosody BOSH endpoint.";
 end
 
-module:depends("http");
-module:provides("http", {
-	default_path = "/http-bind";
-	route = {
-		["GET"] = GET_response;
-		["GET /"] = GET_response;
-		["POST"] = handle_POST;
-		["POST /"] = handle_POST;
-	};
-});
+function module.add_host(module)
+	module:depends("http");
+	module:provides("http", {
+		default_path = "/http-bind";
+		route = {
+			["GET"] = GET_response;
+			["GET /"] = GET_response;
+			["POST"] = handle_POST;
+			["POST /"] = handle_POST;
+		};
+	});
+end
+
+module:add_host();