comparison mod_auth_http/mod_auth_http.lua @ 4454:8862a80cbd00

mod_auth_http: type fix #1621 Committed-By: Zash
author Ben
date Mon, 25 Jan 2021 08:41:37 +0100
parents 93b12bfd7aa8
children
comparison
equal deleted inserted replaced
4453:0508822361eb 4454:8862a80cbd00
46 method = method_type; 46 method = method_type;
47 headers = { Authorization = auth_creds and ("Basic "..base64(auth_creds)) or nil; }; 47 headers = { Authorization = auth_creds and ("Basic "..base64(auth_creds)) or nil; };
48 } 48 }
49 if method_type == "POST" then 49 if method_type == "POST" then
50 url = api_base.."/"..method_name; 50 url = api_base.."/"..method_name;
51 ex.headers["Content-Type"] = "application/x/www-form-urlencoded"; 51 ex.headers["Content-Type"] = "application/x-www-form-urlencoded";
52 ex.body = encoded_params; 52 ex.body = encoded_params;
53 else 53 else
54 url = api_base.."/"..method_name.."?"..encoded_params; 54 url = api_base.."/"..method_name.."?"..encoded_params;
55 end 55 end
56 56