summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Kozak <spag@golwen.net>2013-08-04 12:16:08 +0200
committerPeter Kozak <spag@golwen.net>2013-08-04 12:16:08 +0200
commitd34489093f1e73a293314d2f4278a10fa618abfd (patch)
treebf5c2ecf33a9b8f1409aab2982fbeb3b90355c0c
parentc77a8ce39f96607822fae569ffb14006334e24b9 (diff)
return value can be false or nil
-rw-r--r--misc/freeswitch/scripts/common/array.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/misc/freeswitch/scripts/common/array.lua b/misc/freeswitch/scripts/common/array.lua
index c3cabec..58a6798 100644
--- a/misc/freeswitch/scripts/common/array.lua
+++ b/misc/freeswitch/scripts/common/array.lua
@@ -41,10 +41,11 @@ end
function expand_variable(variable_path, variable_sets)
for index=1, #variable_sets do
local result = try(variable_sets[index], variable_path);
- if result then
+ if result ~= nil then
return result;
end
end
+ return nil;
end
-- replace variables in a string by array values