Fix header generator

This commit is contained in:
Steven Barth 2009-03-02 20:18:29 +00:00
parent eb64affa39
commit a3079828b4

View file

@ -164,7 +164,7 @@ function request_raw(uri, options)
local message = {(options.method or "GET") .. " " .. path .. " " .. protocol}
for k, v in pairs(headers) do
if type(v) == "string" then
if type(v) == "string" or type(v) == "number" then
message[#message+1] = k .. ": " .. v
elseif type(v) == "table" then
for i, j in ipairs(v) do
@ -322,4 +322,4 @@ function cookie_create(cookie)
end
return table.concat(cookiedata, "; ")
end
end