database_host nil prevention
This commit is contained in:
parent
a85673b66f
commit
fbc34dfab8
|
|
@ -137,11 +137,12 @@
|
|||
database_hostname = row["hostname"];
|
||||
end);
|
||||
--freeswitch.consoleLog("notice", "[xml_handler] sql: " .. sql .. "\n");
|
||||
--freeswitch.consoleLog("notice", "[xml_handler-directory.lua] database_hostname is " .. database_hostname .. "\n");
|
||||
|
||||
--hostname was not found set load_balancing to false to prevent a database_hostname concatenation error
|
||||
if (database_hostname == nil) then
|
||||
load_balancing = false;
|
||||
else
|
||||
--freeswitch.consoleLog("notice", "[xml_handler-directory.lua] database_hostname is " .. database_hostname .. "\n");
|
||||
end
|
||||
|
||||
--close the database connection
|
||||
|
|
|
|||
Loading…
Reference in New Issue