「Module:SafeCate」修訂間的差異

增加 1,465 位元組 、 2022年11月5日 (六) 20:45
创建页面,内容为“local module = {} local function _isvalid(value) return value ~= nil and type(value) == "string" and mw.text.trim(value) ~= "" end function module.main(frame) local strict = frame local parent = frame:getParent() if not _isvalid(frame.args[1]) then if not (parent and _isvalid(parent.args[1])) then return end local title = parent:getTitle() if title == "Template:SafeCate" then strict, frame = parent, parent elseif mw.title.new(title).namespace…”
(创建页面,内容为“local module = {} local function _isvalid(value) return value ~= nil and type(value) == "string" and mw.text.trim(value) ~= "" end function module.main(frame) local strict = frame local parent = frame:getParent() if not _isvalid(frame.args[1]) then if not (parent and _isvalid(parent.args[1])) then return end local title = parent:getTitle() if title == "Template:SafeCate" then strict, frame = parent, parent elseif mw.title.new(title).namespace…”)
 
(無差異)