Module:Item Products: Difference between revisions
From Guinea Isles Wiki
Created page with "local p = {} function _main(args) local item_id = nil if args["id"] ~= nil then item_id = args["id"] else item_id = mw.title.getCurrentTitle.text end return item_id end function main(frame) local args = frame:getParent().args return _main(args) end return p" |
No edit summary |
||
| Line 1: | Line 1: | ||
local p = {} | local p = {} | ||
function _main(args) | function p._main(args) | ||
local item_id = nil | local item_id = nil | ||
if args["id"] ~= nil then | if args["id"] ~= nil then | ||
| Line 12: | Line 12: | ||
end | end | ||
function main(frame) | function p.main(frame) | ||
local args = frame:getParent().args | local args = frame:getParent().args | ||
return _main(args) | return _main(args) | ||
Revision as of 16:42, 20 September 2025
Documentation for this module may be created at Module:Item Products/doc
local p = {}
function p._main(args)
local item_id = nil
if args["id"] ~= nil then
item_id = args["id"]
else
item_id = mw.title.getCurrentTitle.text
end
return item_id
end
function p.main(frame)
local args = frame:getParent().args
return _main(args)
end
return p