From: Vsevolod Stakhov Date: Thu, 15 Oct 2015 21:26:01 +0000 (+0100) Subject: Minor fixes to settings. X-Git-Tag: 1.0.6~7 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=665971625a939d5f8e5f41e99636f4e74ebca5d3;p=rspamd.git Minor fixes to settings. --- diff --git a/src/plugins/lua/settings.lua b/src/plugins/lua/settings.lua index 80792ce2b..8c464431d 100644 --- a/src/plugins/lua/settings.lua +++ b/src/plugins/lua/settings.lua @@ -29,7 +29,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- https://rspamd.com/doc/configuration/settings.html local set_section = rspamd_config:get_all_opt("settings") -if not set_section then return end + local settings = { [1] = {}, [2] = {}, @@ -461,6 +461,8 @@ local function process_settings_map(string) process_settings_table(obj) end end + + return res end if set_section[1] and type(set_section[1]) == "string" then diff --git a/test/functional/configs/stats.conf b/test/functional/configs/stats.conf index c03c8b52e..06c1884aa 100644 --- a/test/functional/configs/stats.conf +++ b/test/functional/configs/stats.conf @@ -59,3 +59,5 @@ classifier { path = ${STATSDIR}/rspamd-bats-cache.sqlite; } } + +settings {}