To create new wiki account, please join us on #znc at Libera.Chat and ask admins to create a wiki account for you. You can say thanks to spambots for this inconvenience.
Module:ChangeLog: Difference between revisions
Jump to navigation
Jump to search
DarthGandalf (talk | contribs) No edit summary |
DarthGandalf (talk | contribs) No edit summary |
||
Line 2: | Line 2: | ||
function p.prev(frame) | function p.prev(frame) | ||
local versions = mw.text.split(frame:expandTemplate{title='ZNC-Versions'}, '%s') | local versions = mw.text.split(frame:expandTemplate{title='ZNC-Versions'}, '%s') | ||
local | local prev = nil | ||
for i = 1, #versions, 1 do | for i = 1, #versions, 1 do | ||
if versions[i] == frame.args.this then | |||
prev = i - 1 | |||
end | |||
end | end | ||
return | return tostring(prev) | ||
end | end | ||
function p.next(frame) | function p.next(frame) |
Revision as of 09:06, 2 April 2017
Documentation for this module may be created at Module:ChangeLog/doc
local p = {}
function p.prev(frame)
local versions = mw.text.split(frame:expandTemplate{title='ZNC-Versions'}, '%s')
local prev = nil
for i = 1, #versions, 1 do
if versions[i] == frame.args.this then
prev = i - 1
end
end
return tostring(prev)
end
function p.next(frame)
return 'Hello'
end
function p.stability(frame)
return 'stable'
end
return p