Update sofia.conf.lua

This commit is contained in:
FusionPBX 2019-08-08 02:21:35 -06:00 committed by GitHub
parent 02378c5472
commit 5ac1ee761f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 9 deletions

View File

@ -126,15 +126,10 @@
--table.insert(xml, [[ <X-PRE-PROCESS cmd="include" data="]]..sip_profile_name..[[/*.xml"/>]]);
--get the gateways
if (domain_count > 1) then
sql = "select * from v_gateways as g, v_domains as d ";
sql = sql .. "where g.profile = :profile ";
sql = sql .. "and g.enabled = 'true' ";
sql = sql .. "and (g.domain_uuid = d.domain_uuid or g.domain_uuid is null) ";
else
sql = "select * from v_gateways as g ";
sql = sql .. "where g.enabled = 'true' and g.profile = :profile ";
end
sql = "select * from v_gateways as g, v_domains as d ";
sql = sql .. "where g.profile = :profile ";
sql = sql .. "and g.enabled = 'true' ";
sql = sql .. "and (g.domain_uuid = d.domain_uuid or g.domain_uuid is null) ";
sql = sql .. "and (g.hostname = :hostname or g.hostname is null or g.hostname = '') ";
local params = {profile = sip_profile_name, hostname = hostname};
if (debug["sql"]) then