diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2021-09-22 11:10:59 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2021-09-22 11:10:59 +0100 |
commit | f879e676a216443d648edffc6d37322001a8994d (patch) | |
tree | d4d4b559369f23e0b54851c3d270fceb10969a24 /lualib/lua_selectors | |
parent | 1e373d37b42730f5d67473eeaf3c964ae473e692 (diff) | |
download | rspamd-f879e676a216443d648edffc6d37322001a8994d.tar.gz rspamd-f879e676a216443d648edffc6d37322001a8994d.zip |
[Fix] Another try to fix rspamd_text passing in the selectors
Suggested by: @citrin
Diffstat (limited to 'lualib/lua_selectors')
-rw-r--r-- | lualib/lua_selectors/init.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lualib/lua_selectors/init.lua b/lualib/lua_selectors/init.lua index 726f7d394..eabf14b27 100644 --- a/lualib/lua_selectors/init.lua +++ b/lualib/lua_selectors/init.lua @@ -57,7 +57,7 @@ local function implicit_tostring(t, ud_or_table) end return logger.slog("%s", ud_or_table),'string' - elseif t == 'userdata' then + elseif (t == 'string' or t == 'text') and type(ud_or_table) == 'userdata' then if ud_or_table.cookie and ud_or_table.cookie == text_cookie then -- Preserve opaque return ud_or_table,'string' @@ -73,7 +73,7 @@ end local function process_selector(task, sel) local function allowed_type(t) - if t == 'string' or t == 'text' or t == 'string_list' or t == 'text_list' then + if t == 'string' or t == 'string_list' then return true end |