Made the list returned by solvitdb.list() iterable

This commit is contained in:
2026-05-03 18:31:48 +03:00
parent 56a849c1a8
commit 95b1c56d65
+6
View File
@@ -201,6 +201,12 @@ function solvitdb.list(path)
for index, _ in pairs(pat) do
table.insert(list, index)
end
setmetatable(list, {
__call = function(self)
i, value = next(self, i)
return i, value
end,
})
return list
end