From 08bf11078d67665968283b1b83bd2cf8de51f7b7 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Sat, 27 Feb 2021 23:05:35 +0000 Subject: [PATCH] [Minor] Fix empty table check --- lualib/lua_mime.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lualib/lua_mime.lua b/lualib/lua_mime.lua index 5b1c857e9d..d94335f5b7 100644 --- a/lualib/lua_mime.lua +++ b/lualib/lua_mime.lua @@ -535,6 +535,9 @@ exports.modify_headers = function(task, hdr_alterations) if not hdr_flattened[hname] then hdr_flattened[hname] = {remove = {}} end + if not hdr_flattened[hname].remove then + hdr_flattened[hname].remove = {} + end local remove_tbl = hdr_flattened[hname].remove if type(hdr) == 'number' then table.insert(remove_tbl, hdr) -- 2.47.3