Module:PrevNext/sandbox

local p = {};

p.prev = function (frame) local epCall = require('Module:Ep/Switcher') local current = epCall.epSwitcher(frame, reference) local i, j = string.find(current,"x") local camp = string.sub(current,1,i-1) local ep = string.sub(current,j+1) local prev = ep - 1 return camp .. 'x' .. prev end

p.next = function (frame) local epCall = require('Module:Ep/Switcher') local current = epCall.epSwitcher(frame, reference) local i, j = string.find(current,"x") local camp = string.sub(current,1,i-1) local ep = string.sub(current,j+1) local next = ep + 1 return camp .. 'x' .. next end

return p