Module:Update history: Difference between revisions
m test with if lang |
mNo edit summary |
||
(8 intermediate revisions by the same user not shown) | |||
Line 22: | Line 22: | ||
function p.getRecentUpdates(frame) | function p.getRecentUpdates(frame) | ||
local | local title = mw.title.getCurrentTitle() | ||
local | local pageName = title.baseText | ||
local lang = frame.args[1] or '' | |||
local pageTitle | |||
if lang ~= '' then | |||
pageTitle = pageName .. '/Update history/' .. lang | |||
else | |||
pageTitle = pageName .. '/Update history' | |||
end | |||
local historyPage = mw.title.new(pageTitle) | local historyPage = mw.title.new(pageTitle) |