Handles the async wrapping of the mod_muc_size functions

fixes handling of keyserver ASAP validation of tokens
wraps room and room-size APIs
This commit is contained in:
Aaron van Meerten 2017-07-20 16:04:16 -05:00
parent 22e9dc9893
commit b6efdb533d
1 changed files with 3 additions and 2 deletions

View File

@ -9,6 +9,7 @@ local it = require "util.iterators";
local json = require "util.json";
local iterators = require "util.iterators";
local array = require"util.array";
local wrap_async_run = module:require "util".wrap_async_run;
local tostring = tostring;
local neturl = require "net.url";
@ -192,9 +193,9 @@ function module.load()
module:provides("http", {
default_path = "/";
route = {
["GET room-size"] = handle_get_room_size;
["GET room-size"] = function (event) return wrap_async_run(event,handle_get_room_size) end;
["GET sessions"] = function () return tostring(it.count(it.keys(prosody.full_sessions))); end;
["GET room"] = handle_get_room;
["GET room"] = function (event) return wrap_async_run(event,handle_get_room) end;
};
});
end