WrightKD commented on issue #11646: URL: https://github.com/apache/apisix/issues/11646#issuecomment-2414570392
The issue might be here : [remove namespace](https://github.com/apache/apisix/blob/695ea3c29d067d3a445872974e59dff99b505499/apisix/plugins/body-transformer.lua#L82C1-L85C12) ```lua local function remove_namespace(tbl) for k, v in pairs(tbl) do if type(v) == "table" and next(v) == nil then v = "" tbl[k] = v end if type(k) == "string" then local newk = k:match(".*:(.*)") if newk then tbl[newk] = v tbl[k] = nil end if type(v) == "table" then remove_namespace(v) end end end return tbl end ``` If we look at the below section from the function : ```lua if type(v) == "table" and next(v) == nil then v = "" tbl[k] = v end ``` If the first loop of the remove_namespace, goes into the if statement , then I can reproduce the exact error. I'm still investigating how the if-statement will be true for the first loop. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
