Line 39:
Line 39:
function Iterator.shipsByNo(context, n)
function Iterator.shipsByNo(context, n)
+
local extra = stringKey('extra', context, n)
local function prefix(i)
local function prefix(i)
−
if n == 2 then
+
if extra then
i = i + 1300
i = i + 1300
end
end
return (i - 1) % 10 == 0 and string.format('!%d-%d', i, i - 1 + 10)
return (i - 1) % 10 == 0 and string.format('!%d-%d', i, i - 1 + 10)
end
end
−
local collection = require('Module:Collection/ShipsByNo' .. (n == 2 and 2 or 1))
+
local collection = require('Module:Collection/ShipsByNo' .. (extra and 2 or 1))
local i = 0
local i = 0
local current
local current