From 4ee1209a85ce5b07de46ad04516ec90b084d7dee Mon Sep 17 00:00:00 2001 From: Rcyyy <51192677+Rcyyy@users.noreply.github.com> Date: Fri, 26 Jan 2024 19:43:31 +0800 Subject: [PATCH] [fix] fix bug of creating request body (#100) --- README.md | 2 ++ src/resty/aws/request/build.lua | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 3be5a9f..82468bf 100644 --- a/README.md +++ b/README.md @@ -180,6 +180,8 @@ Release process: - fix: aws configuration cannot be loaded due to pl.path cannot resolve the path started with ~ [94](https://github.com/Kong/lua-resty-aws/pull/94) +- fix: fix the bug of missing boolean type with a value of false in the generated request body + [100](https://github.com/Kong/lua-resty-aws/pull/100) ### 1.3.6 (25-Dec-2023) diff --git a/src/resty/aws/request/build.lua b/src/resty/aws/request/build.lua index e4b2458..6ed96a2 100644 --- a/src/resty/aws/request/build.lua +++ b/src/resty/aws/request/build.lua @@ -27,7 +27,7 @@ local function poor_mans_xml_encoding(output, shape, shape_name, data, indent) if shape.type == "structure" then for name, member in pairs(shape.members) do - if data[name] then + if data[name] ~= nil then poor_mans_xml_encoding(output, member, name, data[name], indent + 1) end end