Software /
code /
prosody
Comparison
plugins/mod_actions_http.lua @ 700:9666ad50a353
mod_actions_http: Show tables as 'list's
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 12 Jan 2009 04:13:05 +0000 |
parent | 699:30f5dcb654bd |
child | 1522:569d58d21612 |
comparison
equal
deleted
inserted
replaced
699:30f5dcb654bd | 700:9666ad50a353 |
---|---|
51 for k,v in pairs(curr) do | 51 for k,v in pairs(curr) do |
52 t_insert(s, tostring(k)); | 52 t_insert(s, tostring(k)); |
53 t_insert(s, " = "); | 53 t_insert(s, " = "); |
54 if type(v) == "function" then | 54 if type(v) == "function" then |
55 t_insert(s, "action") | 55 t_insert(s, "action") |
56 elseif type(v) == "table" then | |
57 t_insert(s, "list"); | |
56 else | 58 else |
57 t_insert(s, tostring(v)); | 59 t_insert(s, tostring(v)); |
58 end | 60 end |
59 t_insert(s, "\n"); | 61 t_insert(s, "\n"); |
60 end | 62 end |