diff --git a/resources/install/scripts/app/xml_handler/resources/scripts/languages/languages.lua b/resources/install/scripts/app/xml_handler/resources/scripts/languages/languages.lua index be25d43cec..f0b01d242d 100644 --- a/resources/install/scripts/app/xml_handler/resources/scripts/languages/languages.lua +++ b/resources/install/scripts/app/xml_handler/resources/scripts/languages/languages.lua @@ -120,9 +120,9 @@ sql = sql .. "AND p.phrase_uuid = d.phrase_uuid "; sql = sql .. "AND p.phrase_enabled = 'true' "; sql = sql .. "ORDER BY d.domain_uuid, p.phrase_uuid, d.phrase_detail_order ASC "; - -- if (debug["sql"]) then + if (debug["sql"]) then freeswitch.consoleLog("notice", "[xml_handler] SQL: " .. sql .. "\n"); - -- end + end previous_phrase_uuid = ""; match_tag = "open"; x = 0; @@ -162,16 +162,6 @@ XML_STRING = table.concat(xml, "\n"); end - --send not found - if (XML_STRING == nil) then - XML_STRING = [[ - -
- -
-
]]; - end - --log to the console --freeswitch.consoleLog("notice", "[xml_handler] language " .. XML_STRING .. " \n"); @@ -212,15 +202,14 @@ end end ---if the extension does not exist send "not found" - if (trim(XML_STRING) == "-ERR NOT FOUND" or XML_STRING == nil) then - --send not found but do not cache it - XML_STRING = [[ - -
- -
-
]]; +--if the macro does not exist send "not found", don't cache the not found + if (XML_STRING == nil or trim(XML_STRING) == "-ERR NOT FOUND") then + XML_STRING = [[ + +
+ +
+
]]; end --send the xml to the console