aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--data/sample.lua8
1 files changed, 3 insertions, 5 deletions
diff --git a/data/sample.lua b/data/sample.lua
index 1e3a08731..d3c5ad3df 100644
--- a/data/sample.lua
+++ b/data/sample.lua
@@ -245,11 +245,9 @@ end
-- Revisit association list STackValue instance.
function DefinitionList(items)
local buffer = {}
- for _,item in pairs(items) do
- for k, v in pairs(item) do
- table.insert(buffer,"<dt>" .. k .. "</dt>\n<dd>" ..
- table.concat(v,"</dd>\n<dd>") .. "</dd>")
- end
+ for _,item in ipairs(items) do
+ table.insert(buffer,"<dt>" .. item[1] .. "</dt>\n<dd>" ..
+ table.concat(item[2],"</dd>\n<dd>") .. "</dd>")
end
return "<dl>\n" .. table.concat(buffer, "\n") .. "\n</dl>"
end