spacewander commented on a change in pull request #2965:
URL: https://github.com/apache/apisix/pull/2965#discussion_r548827770



##########
File path: apisix/cli/etcd.lua
##########
@@ -179,14 +179,14 @@ function _M.init(env, show_output)
 
             local post_json_auth = dkjson.encode(json_auth)
             local response_body = {}
-            local _, err = http.request{url = auth_url, method = "POST",
+            local res, err = http.request{url = auth_url, method = "POST",
                                         source = 
ltn12.source.string(post_json_auth),
                                         sink = ltn12.sink.table(response_body),
                                         headers = {["Content-Length"] = 
#post_json_auth}}
             -- In case of failure, request returns nil followed by an error 
message.
             -- Else the first return value is just the number 1

Review comment:
       The first return value isn't the response body?




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to