Module:Mods

local util = require('Module:Utility_functions')

local success, mods = util.requireDataLocalized('Module:Mods/list')

local function getData(name) return mods.byAbbrv[name] or mods.byName[name] or {} end

local function getLink(abbr, text) local mod = getData(abbr) return  .. ( text or mod.localized or abbr ) ..  end

local function getAbbrv(name) return getData(name).abbr or name end

local function getName(name) return getData(name).localized or name end

local function getNameUntranslated(name) return getData(name).name or name end

return { getData = util.wrapForInvoke(getData), getLink = util.wrapForInvoke(getLink), getAbbrv = util.wrapForInvoke(getAbbrv), getName = util.wrapForInvoke(getName), getNameUntranslated = util.wrapForInvoke(getNameUntranslated) }