Open main menu
Home
Random
Nearby
Log in
Settings
About Kancolle Wiki
Disclaimers
Kancolle Wiki
Search
Changes
← Older edit
Newer edit →
Module:Core
(view source)
Revision as of 09:19, 15 August 2016
12 bytes removed
,
8 years ago
m
no edit summary
Line 57:
Line 57:
function Utils.getContext(frame)
function Utils.getContext(frame)
local parentFrame = frame:getParent()
local parentFrame = frame:getParent()
−
local args = getArgs
{
frame = parentFrame}
+
return
{ pagename = parentFrame:getTitle()
,
args
= getArgs{ frame = parentFrame } }
−
args.
pagename = parentFrame:getTitle()
−
return
args
end
end
function Utils.test_context(frame)
function Utils.test_context(frame)
local context = Utils.getContext(frame)
local context = Utils.getContext(frame)
−
return "arg = " .. (context.arg or "?") .. " @ " .. (context.pagename or "?")
+
return "arg = " .. (context
.args
.arg or "?") .. " @ " .. (context.pagename or "?")
end
end
return Utils
return Utils
がか
cssedit, gkautomate
7,064
edits