comparison mod_conversejs/mod_conversejs.lua @ 2933:8858cef9ed27

mod_conversejs: Pass current domain as 'default_domain'
author Kim Alvefur <zash@zash.se>
date Fri, 16 Mar 2018 20:32:35 +0100
parents 3264058ae54f
children 5c60df8b1a07
comparison
equal deleted inserted replaced
2932:4bb3a4b726c9 2933:8858cef9ed27
25 local converse_options = { 25 local converse_options = {
26 bosh_service_url = module:http_url("bosh","/http-bind"); 26 bosh_service_url = module:http_url("bosh","/http-bind");
27 websocket_url = has_ws and module:http_url("websocket","xmpp-websocket"):gsub("^http", "ws") or nil; 27 websocket_url = has_ws and module:http_url("websocket","xmpp-websocket"):gsub("^http", "ws") or nil;
28 authentication = module:get_option_string("authentication") == "anonymous" and "anonymous" or "login"; 28 authentication = module:get_option_string("authentication") == "anonymous" and "anonymous" or "login";
29 jid = module.host; 29 jid = module.host;
30 default_domain = module.host;
30 }; 31 };
31 32
32 local view_mode_css = "converse"; 33 local view_mode_css = "converse";
33 if type(more_options) == "table" then 34 if type(more_options) == "table" then
34 for k,v in pairs(more_options) do 35 for k,v in pairs(more_options) do