More actions
No edit summary |
No edit summary |
||
Line 7: | Line 7: | ||
local function format_media(args) | local function format_media(args) | ||
mw.log('format_media: args received:') | |||
mw.logObject(args) | |||
local str = '' | local str = '' | ||
Revision as of 22:36, 3 April 2025
Documentation for this module may be created at Module:ObbyInfobox/doc
-- inspired by roblox.fandom.com
local utils = require('Module:Utils')
local config_external = require('Module:Config_external')
local media = config_external.media
local function format_media(args)
mw.log('format_media: args received:')
mw.logObject(args)
local str = ''
for i, v in pairs(media) do
if args[i] then
str = str .. ' ' .. (' [[File:' .. v.file .. '|28px|link=' .. v.url_form:format(args[v[1]]) .. ']]')
end
end
return str
end
return {
['format_media'] = utils.wrap_function(format_media, true);
}