summaryrefslogtreecommitdiffstats
path: root/lualib
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2018-09-20 10:51:33 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2018-09-20 10:51:46 +0100
commitd82bb62834c158a2108ceb412745b046b2990b9f (patch)
tree3eae542a09b125f9809ae675705b4e5eb37468af /lualib
parent328ddb84bfeb08b1203c12316a69b629ecb00e5e (diff)
downloadrspamd-d82bb62834c158a2108ceb412745b046b2990b9f.tar.gz
rspamd-d82bb62834c158a2108ceb412745b046b2990b9f.zip
[Minor] Fix implicit conversion
Diffstat (limited to 'lualib')
-rw-r--r--lualib/lua_selectors.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/lualib/lua_selectors.lua b/lualib/lua_selectors.lua
index 983f28589..ad18feddf 100644
--- a/lualib/lua_selectors.lua
+++ b/lualib/lua_selectors.lua
@@ -569,9 +569,7 @@ local function process_selector(task, sel)
end
local function implicit_tostring(t, ud_or_table)
- if t == 'userdata' then
- return tostring(ud_or_table),'string'
- else
+ if t == 'table' then
-- Table (very special)
if ud_or_table.value then
return ud_or_table.value,'string'
@@ -580,6 +578,8 @@ local function process_selector(task, sel)
end
return logger.slog("%s", ud_or_table),'string'
+ else
+ return tostring(ud_or_table),'string'
end
end