"ഘടകം:Wd" എന്ന താളിന്റെ പതിപ്പുകൾ തമ്മിലുള്ള വ്യത്യാസം
Content deleted Content added
(ചെ.) Changed protection level for "Module:Wd": High-risk Lua module: 5,000+ transclusions ([Edit=Require extended confirmed access] (indefinite)) |
imported>Pppery Simplify and deduplicate error handling code |
||
വരി 215:
return str
end
function errorText(code, param)
local error = i18n["errors"][error]
if param then error = applyStringPars(error, param) end
return error
end
function throwError(error, param)
error(errorText(param))
return i18n['errors']['missing-required-parameter']▼
end
Line 585 ⟶ 581:
-- make sure that at least one required parameter has been defined
if not next(root.req) then
end
-- make sure that the separator parameter "%s" is not amongst the required parameters
if root.req[parameters.separator] then
end
Line 1,219 ⟶ 1,215:
itemID = "P" .. itemID
else
return '<strong class="error">' ..
end
Line 1,230 ⟶ 1,226:
return label
else
return '<strong class="error">' ..
end
elseif snak.snaktype == 'somevalue' and not noSpecial then
Line 2,531 ⟶ 2,527:
if not frame.args[1] then
end
Line 2,537 ⟶ 2,533:
if f == "main" then
end
assert(p["_"..f],
-- copy arguments from immutable to mutable table
|