瀏覽代碼

Revert "Adds a second parameter named domain to muc_size module."

This reverts commit e2e04e3f16.
j8
damencho 8 年之前
父節點
當前提交
e0b829f92f
共有 1 個文件被更改,包括 4 次插入8 次删除
  1. 4
    8
      resources/prosody-plugins/mod_muc_size.lua

+ 4
- 8
resources/prosody-plugins/mod_muc_size.lua 查看文件

@@ -40,12 +40,10 @@ end
40 40
 function handle_get_room_size(event)
41 41
 	local params = parse(event.request.url.query);
42 42
 	local room_name = params["room"];
43
-	local domain_name = params["domain"];
44
-	local room_address = room_name .. "@" .. domain_name;
45
-	local room = get_room_from_jid(room_address);
43
+	local room = get_room_from_jid(room_name);
46 44
 	local participant_count = 0;
47 45
 
48
-	log("debug", "Querying room %s", tostring(room_address));
46
+	log("debug", "Querying room %s", tostring(room_name));
49 47
 
50 48
 	if room then
51 49
 		local occupants = room._occupants;
@@ -73,13 +71,11 @@ end
73 71
 function handle_get_room (event)
74 72
 	local params = parse(event.request.url.query);
75 73
 	local room_name = params["room"];
76
-	local domain_name = params["domain"];
77
-	local room_address = room_name .. "@" .. domain_name;
78
-	local room = get_room_from_jid(room_address);
74
+	local room = get_room_from_jid(room_name);
79 75
 	local participant_count = 0;
80 76
 	local occupants_json = array();
81 77
 
82
-	log("debug", "Querying room %s", tostring(room_address));
78
+	log("debug", "Querying room %s", tostring(room_name));
83 79
 
84 80
 	if room then
85 81
 		local occupants = room._occupants;

Loading…
取消
儲存