Module:EpisodeLink

-- This module was taken and adapted from the Darbi Wiki and the Boxer Wiki -- -- -- -- This module needs to be updated every Sunday when a new episode is released on Webtoon. -- -- -- How webtoon numbering is calculated: -- Episodes 1 onwards: episode # -- -- local p = {} function p.GetNumber( frame ) local LATEST_WEBTOONS = 19 -- Update this on Sundays - most recent episode # local site = frame.args[1] local anchor = frame.args[2] local episode = frame.args[3] local LinkNumber = 0 local LinkTxt = "Something went wrong." if (site == "line") then if (anchor == "1") then LinkNumber = episode end if (episode <= LATEST_WEBTOONS) then LinkTxt = "[https://webtoons.com/viewer?titleNo=2009&episodeNo=" .. LinkNumber .. " LINE Episode]" else LinkTxt = "Not yet available on Webtoon" end end return LinkTxt end return p --