diff --git a/app/scripts/resources/scripts/app/xml_handler/resources/scripts/configuration/acl.conf.lua b/app/scripts/resources/scripts/app/xml_handler/resources/scripts/configuration/acl.conf.lua index 480be60084..abf381697b 100644 --- a/app/scripts/resources/scripts/app/xml_handler/resources/scripts/configuration/acl.conf.lua +++ b/app/scripts/resources/scripts/app/xml_handler/resources/scripts/configuration/acl.conf.lua @@ -102,7 +102,9 @@ --add the domains if (row.access_control_name == 'providers' or row.access_control_name == 'domains') then sql = "select domain_name, domain_description from v_domains "; - sql = sql .. "where domain_uuid in (select distinct(domain_uuid) from v_extensions where domain_enabled = 'true') "; + sql = sql .. "where domain_uuid in (select distinct(domain_uuid) "; + sql = sql .. "from v_extensions where enabled = 'true') "; + sql = sql .. "and domain_enabled = 'true' "; local params = {} if (debug["sql"]) then freeswitch.consoleLog("notice", "[xml_handler] SQL: " .. sql .. ";\n");