Module:Sandbox/Minibug

Documentation for this module may be created at Module:Sandbox/Minibug/doc

local p = {}

function p.main( frame )
    local epicode = frame.args[1]
    local epicodeData = ""
    local output = ""
	
    epicodeData = mw.loadData( 'Module:Sandbox/Minibug/data' )
    output = epicodeData[epicode]
    if output == nil then
        return "'''Episode not found'''"
    elseif output == "" then
        return "[[" .. epicode .. "]]"
    else
        return "''[[" .. epicode .. "|" .. output .. "]]''"
    end
end

return p