FANDOM


local p = {}
 
function p.getEp(frame)
    local episodesManga = mw.loadData( 'Module:Episodes/mangaData' )
    local args = frame:getParent().args
    local epKey = args[1]:match( 'e?([0-9A-P]*)' ) or ''
    local epVal = episodesManga[epKey]
    local epName = epVal['ename']
    local toLink = args['link']
    local epOutput
 
    if args['full'] == 'yes' then
        epOutput = '<i>[[Berserk (Manga)|Berserk]]</i>, ' .. 'Volume ' .. epVal['volume'] .. ', "[[Episode ' .. epKey .. ' (Manga)|' .. epName .. ']]"'
    else
        if toLink == 'no' then
            epOutput = '"' .. epName .. '"'
        else
            epOutput = '"[[Episode ' .. epKey .. ' (Manga)|' .. epName .. ']]"'
        end
    end
 
    return epOutput
end
 
return p
 
-- [[Category:Lua Modules]]
Community content is available under CC-BY-SA unless otherwise noted.