Closed ruslandoga closed 5 months ago
Nice, thanks @ruslandoga, and apologies for the delay getting to this.
Thank you!
Is there a way to allow iodata in that case statement?
def request(http_method, url, data, headers, config, service) do
body =
case data do
[] -> "{}"
d when is_binary(d) or is_list(d) -> d
_ -> config[:json_codec].encode!(data)
end
request_and_retry(http_method, url, service, config, headers, body, {:attempt, 1})
end
could be problematic if non-encoded lists can come from other requests. Is it maybe possible to check by service if JSON encoding is required? I'll try to explore that route in a "encode to JSON only when necessary" PR.
👋
This PR makes iodata ops possible in ExAws.S3.