util.dataforms: Fix parsing of -multi fields

This commit is contained in:
Florian Zeitz 2012-06-12 18:29:58 +02:00
parent f76c2aa90b
commit 49d3586dc1

View file

@ -185,7 +185,7 @@ field_readers["list-multi"] =
function (field_tag, required)
local result = {};
for value in field_tag:childtags("value") do
result[#result+1] = value;
result[#result+1] = value:get_text();
end
return result, (required and #result == 0 and "Required value missing" or nil);
end