function create_ajax_handler(fn)
return function(req, res)
res.headers["Content-Type"] = "text/plain"
res.content = fn(req)
return res
end
end
Inside the function I pass in (fn), req.params is nil. I've tried adding xavante.httpd.getparams(req), which works fine and populates req.params with URL params, but seems to totally ignore post data.