comparison http/src/luan/modules/http/run.luan @ 497:55f9f74f1e55

Http.request is now pure luan
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 17 May 2015 19:25:47 -0600
parents 598123096772
children ee55be414a34
comparison
equal deleted inserted replaced
496:c65df5b25932 497:55f9f74f1e55
47 </html> 47 </html>
48 <% end 48 <% end
49 49
50 function respond() 50 function respond()
51 Io.stdout = Http.response.text_writer() 51 Io.stdout = Http.response.text_writer()
52 local code = Http.request.parameters.code 52 local code = Http.request.parameter.code
53 if code == nil then 53 if code == nil then
54 form() 54 form()
55 return 55 return
56 end 56 end
57 local content_type = Http.request.parameters.content_type 57 local content_type = Http.request.parameter.content_type
58 if content_type ~= nil then 58 if content_type ~= nil then
59 Http.response.content_type = content_type 59 Http.response.content_type = content_type
60 end 60 end
61 local env = { 61 local env = {
62 request = Http.request; 62 request = Http.request;