Module:Sidebar: Difference between revisions
if args.name isn't specified, let Module:Navbar try to guess the name (it does a slightly better job than the current page's title, which is almost always wrong) |
use Module:Arguments |
||
Line 5: | Line 5: | ||
local p = {} | local p = {} | ||
local getArgs | |||
local HtmlBuilder = require('Module:HtmlBuilder') | local HtmlBuilder = require('Module:HtmlBuilder') | ||
local navbar = require('Module:Navbar')._navbar | local navbar = require('Module:Navbar')._navbar | ||
Line 275: | Line 276: | ||
function makeWrapper(func) | function makeWrapper(func) | ||
return function(frame) | return function(frame) | ||
if not getArgs then | |||
if | getArgs = require('Module:Arguments').getArgs | ||
end | end | ||
return func(getArgs(frame)) | |||
return func( | |||
end | end | ||
end | end |