aboutsummaryrefslogtreecommitdiffstats
path: root/tools/migration/migrator/mtools.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tools/migration/migrator/mtools.lua')
-rw-r--r--tools/migration/migrator/mtools.lua10
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/migration/migrator/mtools.lua b/tools/migration/migrator/mtools.lua
index e7b774bb..cfbfcce8 100644
--- a/tools/migration/migrator/mtools.lua
+++ b/tools/migration/migrator/mtools.lua
@@ -4,9 +4,8 @@ local print = print;
local t_insert = table.insert;
local t_sort = table.sort;
-module "mtools"
-function sorted(params)
+local function sorted(params)
local reader = params.reader; -- iterator to get items from
local sorter = params.sorter; -- sorting function
@@ -28,7 +27,7 @@ function sorted(params)
end
-function merged(reader, merger)
+local function merged(reader, merger)
local item1 = reader();
local merged = { item1 };
@@ -53,4 +52,7 @@ function merged(reader, merger)
end
-return _M;
+return {
+ sorted = sorted;
+ merged = merged;
+}