Jump to content

Module:Check blp parameter

Permanently protected module
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by MSGJ (talk | contribs) at 20:44, 7 September 2024 (fix). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

require('strict')
local p = {}

p.main = function(frame)
	local yesno = require('Module:Yesno')
	local page = mw.title.getCurrentTitle().fullText
	local templates = mw.loadData('Module:WikiProject banner/config').banner_shell.redirects
	local getparam = function(p)
		local TPVmodule = require('Module:Template parameter value').getParameter
		local success, param = TPVmodule(page, templates, p, {ignore_subtemplates=true, ignore_blank=true})
		return yesno(success and param)
	end
	local shell_blp = getparam('blp')
	local shell_living = getparam('living')
	return 'blp=' .. tostring(shell_blp) .. ' living=' .. tostring(shell_living)
end

return p